-
Type:
Build Failure
-
Resolution: Duplicate
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
None
-
Python Drivers
-
None
-
None
-
None
-
None
-
None
-
None
Name of Failure:
test.test_client_context.TestClientContext.test_must_connect
Link to task:
Context of when and why the failure occurred:
Started failing on Apr 13, 2026 when the backpressure branch was merged (PYTHON-5668).
Stack trace:
[2026/05/30 14:01:14.428] FAILURE: AssertionError: False is not true : client context must be connected when PYMONGO_MUST_CONNECT is set. Failed attempts: [2026/05/30 14:01:14.428] failed to connect client MongoClient(host=['localhost:27017'], document_class=dict, tz_aware=False, connect=True, serverselectiontimeoutms=5000): localhost:27017: connection closed (configured timeouts: socketTimeoutMS: 20000.0ms, connectTimeoutMS: 20000.0ms), Timeout: 5.0s, Topology Description: <TopologyDescription id: 6a1b33dda11b84544b7c001d, topology_type: Unknown, servers: [<ServerDescription ('localhost', 27017) server_type: Unknown, rtt: None, error=AutoReconnect('localhost:27017: connection closed (configured timeouts: socketTimeoutMS: 20000.0ms, connectTimeoutMS: 20000.0ms)')>]> [2026/05/30 14:01:14.428] failed to connect client MongoClient(host=['localhost:27017'], document_class=dict, tz_aware=False, connect=True, serverselectiontimeoutms=5000, tls=True, tlscertificatekeyfile='/data/mci/8215cedf73a68a9ff24f7fc1b71609e4/drivers-tools/.evergreen/x509gen/client.pem', tlscafile='/data/mci/8215cedf73a68a9ff24f7fc1b71609e4/drivers-tools/.evergreen/x509gen/ca.pem'): 'X509' object has no attribute 'get_extension', Timeout: 5.0s, Topology Description: <TopologyDescription id: 6a1b33e2a11b84544b7c001e, topology_type: Unknown, servers: [<ServerDescription ('localhost', 27017) server_type: Unknown, rtt: None, error=AttributeError("'X509' object has no attribute 'get_extension'")>]> () [2026/05/30 14:01:14.428] self = <test.test_client_context.TestClientContext testMethod=test_must_connect> [2026/05/30 14:01:14.428] def test_must_connect(self): [2026/05/30 14:01:14.428] if not os.environ.get("PYMONGO_MUST_CONNECT"): [2026/05/30 14:01:14.428] raise SkipTest("PYMONGO_MUST_CONNECT is not set") [2026/05/30 14:01:14.428] [2026/05/30 14:01:14.428] > self.assertTrue( [2026/05/30 14:01:14.428] client_context.connected, [2026/05/30 14:01:14.428] "client context must be connected when " [2026/05/30 14:01:14.428] "PYMONGO_MUST_CONNECT is set. Failed attempts:\n{}".format( [2026/05/30 14:01:14.428] client_context.connection_attempt_info() [2026/05/30 14:01:14.428] ), [2026/05/30 14:01:14.428] ) [2026/05/30 14:01:14.428] E AssertionError: False is not true : client context must be connected when PYMONGO_MUST_CONNECT is set. Failed attempts: [2026/05/30 14:01:14.428] E failed to connect client MongoClient(host=['localhost:27017'], document_class=dict, tz_aware=False, connect=True, serverselectiontimeoutms=5000): localhost:27017: connection closed (configured timeouts: socketTimeoutMS: 20000.0ms, connectTimeoutMS: 20000.0ms), Timeout: 5.0s, Topology Description: <TopologyDescription id: 6a1b33dda11b84544b7c001d, topology_type: Unknown, servers: [<ServerDescription ('localhost', 27017) server_type: Unknown, rtt: None, error=AutoReconnect('localhost:27017: connection closed (configured timeouts: socketTimeoutMS: 20000.0ms, connectTimeoutMS: 20000.0ms)')>]> [2026/05/30 14:01:14.428] E failed to connect client MongoClient(host=['localhost:27017'], document_class=dict, tz_aware=False, connect=True, serverselectiontimeoutms=5000, tls=True, tlscertificatekeyfile='/data/mci/8215cedf73a68a9ff24f7fc1b71609e4/drivers-tools/.evergreen/x509gen/client.pem', tlscafile='/data/mci/8215cedf73a68a9ff24f7fc1b71609e4/drivers-tools/.evergreen/x509gen/ca.pem'): 'X509' object has no attribute 'get_extension', Timeout: 5.0s, Topology Description: <TopologyDescription id: 6a1b33e2a11b84544b7c001e, topology_type: Unknown, servers: [<ServerDescription ('localhost', 27017) server_type: Unknown, rtt: None, error=AttributeError("'X509' object has no attribute 'get_extension'")>]> [2026/05/30 14:01:14.428] test/test_client_context.py:31: AssertionError
- is fixed by
-
PYTHON-5849 [Build Failure] TestOCSP.test_tls
-
- Closed
-