Uploaded image for project: 'Python Driver'
  1. Python Driver
  2. PYTHON-3348

[v3.13] test_session_authenticate_multiple failing on Windows and macOS

    • Type: Icon: Build Failure Build Failure
    • Resolution: Duplicate
    • Priority: Icon: Unknown Unknown
    • None
    • Affects Version/s: None
    • Component/s: None
    • None

      Running a patch build of the encryption tests with crypt_shared on v3.13 of PyMongo, yields the following error on 'latest' server version with both macOS and Windows:

       

       [2022/07/08 21:12:53.555] Traceback (most recent call last):
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\test\utils.py", line 794, in wrapper
       [2022/07/08 21:12:53.555]     return wrapped(*args, **kwargs)
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\test\test_session.py", line 1145, in test_session_authenticate_multiple
       [2022/07/08 21:12:53.555]     db.authenticate("second-user", "pass")
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\database.py", line 1687, in authenticate
       [2022/07/08 21:12:53.555]     self.client._cache_credentials(self.name, credentials, connect=True)
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\mongo_client.py", line 830, in _cache_credentials
       [2022/07/08 21:12:53.555]     sock_info.authenticate(credentials)
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\pool.py", line 868, in authenticate
       [2022/07/08 21:12:53.555]     auth.authenticate(credentials, self)
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\auth.py", line 679, in authenticate
       [2022/07/08 21:12:53.555]     auth_func(credentials, sock_info)
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\auth.py", line 600, in _authenticate_default
       [2022/07/08 21:12:53.555]     return _authenticate_scram(credentials, sock_info, "SCRAM-SHA-256")
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\auth.py", line 331, in _authenticate_scram
       [2022/07/08 21:12:53.555]     res = sock_info.command(source, cmd)
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\pool.py", line 753, in command
       [2022/07/08 21:12:53.555]     exhaust_allowed=exhaust_allowed,
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\network.py", line 181, in command
       [2022/07/08 21:12:53.555]     parse_write_concern_error=parse_write_concern_error,
       [2022/07/08 21:12:53.555]   File "Z:\data\mci\44dc925215cdf8509513a06690979bca\src\pymongo\helpers.py", line 180, in _check_command_response
       [2022/07/08 21:12:53.555]     raise OperationFailure(errmsg, code, response, max_wire_version)
       [2022/07/08 21:12:53.555] pymongo.errors.OperationFailure: Each client connection may only be authenticated once. Previously authenticated as: bob@admin, full error: {'$clusterTime': {'clusterTime': Timestamp(1657314652, 20), 'signature': {'hash': b'\xa7Y\x95\xad\x84b\xa7\x07\xdb\xab\xaf\xca\x00\xf3\x13"\x91{3\xef', 'keyId': 7118109472152616962}}, 'codeName': 'Location5626701', 'operationTime': Timestamp(1657314652, 20), 'errmsg': 'Each client connection may only be authenticated once. Previously authenticated as: bob@admin', 'ok': 0.0, 'code': 5626701}
       [2022/07/08 21:12:53.555] ---------------------------------------------------------------------- 

       

       

            Assignee:
            Unassigned Unassigned
            Reporter:
            julius.park@mongodb.com Julius Park (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: