Skip to content

test failures with python 3.12 #560

Open
@ncopa

Description

@ncopa

Issue description:

...
test_weird_empty_lines (Tests.t_ldif.TestEntryRecords.test_weird_empty_lines) ... ok
test_syncidset_message (Tests.t_ldap_syncrepl.DecodeSyncreplProtoTests.test_syncidset_message)
A syncrepl server may send a sync info message, with a syncIdSet ... ok
test_refreshAndPersist_cancelled (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_cancelled)
Make sure refreshAndPersist can handle cancelling a syncrepl search. ... ok
test_refreshAndPersist_poll_only (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_poll_only)
Test the refresh part of refresh-and-persist, and check what we got. ... ERROR
test_refreshAndPersist_search (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_search) ... ERROR
test_refreshAndPersist_timeout (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_timeout)
Make sure refreshAndPersist can handle a search with timeouts. ... ERROR
test_refreshOnly_poll_full (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshOnly_poll_full)
Test doing a full refresh cycle, and check what we got. ... ERROR
test_refreshOnly_search (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshOnly_search)
Test to see if we can initialize a syncrepl search. ... ERROR

======================================================================
ERROR: test_refreshAndPersist_poll_only (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_poll_only)
Test the refresh part of refresh-and-persist, and check what we got.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 436, in setUp
    self.tester = SyncreplClient(
                  ^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 165, in __init__
    self.simple_bind_s(dn, password)
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 249, in simple_bind_s
    resp_type, resp_data, resp_msgid, resp_ctrls = self.result3(msgid,all=1,timeout=self.timeout)
                                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 543, in result3
    resp_type, resp_data, resp_msgid, decoded_resp_ctrls, retoid, retval = self.result4(
                                                                           ^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 553, in result4
    ldap_result = self._ldap_call(self._l.result4,msgid,all,timeout,add_ctrls,add_intermediates,add_extop)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 128, in _ldap_call
    result = func(*args,**kwargs)
             ^^^^^^^^^^^^^^^^^^^^
ldap.SERVER_DOWN: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 104, 'ctrls': [], 'info': 'Connection reset by peer'}

======================================================================
ERROR: test_refreshAndPersist_search (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_search)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 436, in setUp
    self.tester = SyncreplClient(
                  ^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 165, in __init__
    self.simple_bind_s(dn, password)
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 248, in simple_bind_s
    msgid = self.simple_bind(who,cred,serverctrls,clientctrls)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 242, in simple_bind
    return self._ldap_call(self._l.simple_bind,who,cred,RequestControlTuples(serverctrls),RequestControlTuples(clientctrls))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 128, in _ldap_call
    result = func(*args,**kwargs)
             ^^^^^^^^^^^^^^^^^^^^
ldap.SERVER_DOWN: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Socket not connected'}

======================================================================
ERROR: test_refreshAndPersist_timeout (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshAndPersist_timeout)
Make sure refreshAndPersist can handle a search with timeouts.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 436, in setUp
    self.tester = SyncreplClient(
                  ^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 165, in __init__
    self.simple_bind_s(dn, password)
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 248, in simple_bind_s
    msgid = self.simple_bind(who,cred,serverctrls,clientctrls)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 242, in simple_bind
    return self._ldap_call(self._l.simple_bind,who,cred,RequestControlTuples(serverctrls),RequestControlTuples(clientctrls))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 128, in _ldap_call
    result = func(*args,**kwargs)
             ^^^^^^^^^^^^^^^^^^^^
ldap.SERVER_DOWN: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Socket not connected'}

======================================================================
ERROR: test_refreshOnly_poll_full (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshOnly_poll_full)
Test doing a full refresh cycle, and check what we got.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 436, in setUp
    self.tester = SyncreplClient(
                  ^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 165, in __init__
    self.simple_bind_s(dn, password)
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 248, in simple_bind_s
    msgid = self.simple_bind(who,cred,serverctrls,clientctrls)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 242, in simple_bind
    return self._ldap_call(self._l.simple_bind,who,cred,RequestControlTuples(serverctrls),RequestControlTuples(clientctrls))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 128, in _ldap_call
    result = func(*args,**kwargs)
             ^^^^^^^^^^^^^^^^^^^^
ldap.SERVER_DOWN: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Socket not connected'}

======================================================================
ERROR: test_refreshOnly_search (Tests.t_ldap_syncrepl.TestSyncrepl.test_refreshOnly_search)
Test to see if we can initialize a syncrepl search.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 436, in setUp
    self.tester = SyncreplClient(
                  ^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Tests/t_ldap_syncrepl.py", line 165, in __init__
    self.simple_bind_s(dn, password)
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 248, in simple_bind_s
    msgid = self.simple_bind(who,cred,serverctrls,clientctrls)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 242, in simple_bind
    return self._ldap_call(self._l.simple_bind,who,cred,RequestControlTuples(serverctrls),RequestControlTuples(clientctrls))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ncopa/aports/community/py3-ldap/src/python-ldap-python-ldap-3.4.4/Lib/ldap/ldapobject.py", line 128, in _ldap_call
    result = func(*args,**kwargs)
             ^^^^^^^^^^^^^^^^^^^^
ldap.SERVER_DOWN: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Socket not connected'}

----------------------------------------------------------------------
Ran 253 tests in 7.315s

FAILED (errors=5, skipped=1, expected failures=3)
Test failed: <unittest.runner.TextTestResult run=253 errors=5 failures=0>
error: Test failed: <unittest.runner.TextTestResult run=253 errors=5 failures=0>

Steps to reproduce:

python3 setup.py build
python3 setup.py test

Operating system: Alpine Linux edge (x86_64)

Python version: 3.12.2

python-ldap version: 3.4.4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions