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

Test failure - test_client.TestClient.test_network_error_message

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.0
    • Affects Version/s: None
    • Component/s: Tests
    • None

      The test added in PYTHON-2596 sometimes fails when TLS is enabled:

       [2021/03/13 00:12:28.550] FAIL [0.036s]: test_network_error_message (test_client.TestClient)
       [2021/03/13 00:12:28.550] ----------------------------------------------------------------------
       [2021/03/13 00:12:28.550] Traceback (most recent call last):
       [2021/03/13 00:12:28.550]   File "/data/mci/96d4a3993478a1433dc769d9fa3aeec0/src/pymongo/pool.py", line 708, in receive_message
       [2021/03/13 00:12:28.550]     return receive_message(self, request_id, self.max_message_size)
       [2021/03/13 00:12:28.550]   File "/data/mci/96d4a3993478a1433dc769d9fa3aeec0/src/pymongo/network.py", line 192, in receive_message
       [2021/03/13 00:12:28.550]     _receive_data_on_socket(sock_info, 16, deadline))
       [2021/03/13 00:12:28.550] ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2570)
       [2021/03/13 00:12:28.550] The above exception was the direct cause of the following exception:
       [2021/03/13 00:12:28.550] pymongo.errors.AutoReconnect: localhost:27017: EOF occurred in violation of protocol (_ssl.c:2570)
       [2021/03/13 00:12:28.550] During handling of the above exception, another exception occurred:
       [2021/03/13 00:12:28.550] Traceback (most recent call last):
       [2021/03/13 00:12:28.550]   File "/data/mci/96d4a3993478a1433dc769d9fa3aeec0/src/test/__init__.py", line 496, in wrap
       [2021/03/13 00:12:28.550]     return f(*args, **kwargs)
       [2021/03/13 00:12:28.550]   File "/data/mci/96d4a3993478a1433dc769d9fa3aeec0/src/test/test_client.py", line 1581, in test_network_error_message
       [2021/03/13 00:12:28.550]     client.pymongo_test.test.find_one({})
       [2021/03/13 00:12:28.550] AssertionError: "localhost:27017: connection closed" does not match "localhost:27017: EOF occurred in violation of protocol (_ssl.c:2570)"
      

      https://evergreen.mongodb.com/task/mongo_python_driver_tests_python_version_green_framework_amazon1__platform~awslinux_auth_ssl~auth_ssl_python_version~3.7_green_framework~eventlet_test_latest_standalone_ec6337e3a7a012131d215dd343cbd91a3d6d9f97_21_03_09_20_33_12

      We need to update the test to be more general because TLS errors like this are expected in this particular test.

            Assignee:
            shane.harvey@mongodb.com Shane Harvey
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: