Skip to content

Test failures with Python 3.13.6 #1648

@mweinelt

Description

@mweinelt

With Python 3.13.6 (up from 3.13.5) we started seeing test failures around TLS connections in the test suite on 15.0.1 (and also on 91abba4).

websockets> unittest flags: ''
websockets> .......................................sssssssssssssss.......ssssssss...................................................................................................................................................................s....s.s........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................ss...............................................................................................................................................................................................................................................................................................................................................................E...........................sssssssssssssssE..EEssssssss.E.E.................................................s..............................................................s.s...............................s...................................................................................................................E.E............E..E.............................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................
websockets> ======================================================================
websockets> ERROR: test_ssl_context_argument (tests.sync.test_client.BackwardsCompatibilityTests.test_ssl_context_argument)
websockets> Client supports the deprecated ssl_context argument.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_client.py", line 712, in test_ssl_context_argument
websockets>     with connect(get_uri(server), ssl_context=CLIENT_CONTEXT):
websockets>          ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_connection (tests.sync.test_client.SecureClientTests.test_connection)
websockets> Client connects to server securely.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_client.py", line 261, in test_connection
websockets>     with connect(get_uri(server), ssl=CLIENT_CONTEXT) as client:
websockets>          ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_set_server_hostname_explicitly (tests.sync.test_client.SecureClientTests.test_set_server_hostname_explicitly)
websockets> Client sets server_hostname to the value provided in argument.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_client.py", line 278, in test_set_server_hostname_explicitly
websockets>     with unix_connect(
websockets>          ~~~~~~~~~~~~^
websockets>         path, ssl=CLIENT_CONTEXT, server_hostname="overridden"
websockets>         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>     ) as client:
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 419, in unix_connect
websockets>     return connect(uri=uri, unix=True, path=path, **kwargs)
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_set_server_hostname_implicitly (tests.sync.test_client.SecureClientTests.test_set_server_hostname_implicitly)
websockets> Client sets server_hostname to the host in the WebSocket URI.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_client.py", line 269, in test_set_server_hostname_implicitly
websockets>     with unix_connect(
websockets>          ~~~~~~~~~~~~^
websockets>         path, ssl=CLIENT_CONTEXT, uri="wss://overridden/"
websockets>         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>     ) as client:
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 419, in unix_connect
websockets>     return connect(uri=uri, unix=True, path=path, **kwargs)
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_secure_connection (tests.sync.test_client.UnixClientTests.test_secure_connection)
websockets> Client connects to server securely over a Unix socket.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_client.py", line 620, in test_secure_connection
websockets>     with unix_connect(path, ssl=CLIENT_CONTEXT) as client:
websockets>          ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 419, in unix_connect
websockets>     return connect(uri=uri, unix=True, path=path, **kwargs)
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_set_server_hostname (tests.sync.test_client.UnixClientTests.test_set_server_hostname)
websockets> Client sets server_hostname to the host in the WebSocket URI.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_client.py", line 629, in test_set_server_hostname
websockets>     with unix_connect(
websockets>          ~~~~~~~~~~~~^
websockets>         path, ssl=CLIENT_CONTEXT, uri="wss://overridden/"
websockets>         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>     ) as client:
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 419, in unix_connect
websockets>     return connect(uri=uri, unix=True, path=path, **kwargs)
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_secure_redirect (tests.sync.test_router.RouterTests.test_secure_redirect)
websockets> Router redirects connections to a wss:// URI when TLS is enabled.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_router.py", line 83, in test_secure_redirect
websockets>     with connect(get_uri(server) + "/r", ssl=CLIENT_CONTEXT):
websockets>          ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_ssl_context_argument (tests.sync.test_server.BackwardsCompatibilityTests.test_ssl_context_argument)
websockets> Server supports the deprecated ssl_context argument.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_server.py", line 574, in test_ssl_context_argument
websockets>     with connect(get_uri(server), ssl=CLIENT_CONTEXT):
websockets>          ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_connection (tests.sync.test_server.SecureServerTests.test_connection)
websockets> Server receives secure connection from client.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_server.py", line 346, in test_connection
websockets>     with connect(get_uri(server), ssl=CLIENT_CONTEXT) as client:
websockets>          ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ======================================================================
websockets> ERROR: test_connection (tests.sync.test_server.SecureUnixServerTests.test_connection)
websockets> Server receives secure connection from client over a Unix socket.
websockets> ----------------------------------------------------------------------
websockets> Traceback (most recent call last):
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 963, in send_context
websockets>     self.send_data()
websockets>     ~~~~~~~~~~~~~~^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1029, in send_data
websockets>     self.socket.sendall(data)
websockets>     ~~~~~~~~~~~~~~~~~~~^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1263, in sendall
websockets>     v = self.send(byte_view[count:])
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/ssl.py", line 1232, in send
websockets>     return self._sslobj.write(data)
websockets>            ~~~~~~~~~~~~~~~~~~^^^^^^
websockets> ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2502)
websockets> 
websockets> The above exception was the direct cause of the following exception:
websockets> 
websockets> Traceback (most recent call last):
websockets>   File "/build/source/tests/sync/test_server.py", line 380, in test_connection
websockets>     with unix_connect(path, ssl=CLIENT_CONTEXT) as client:
websockets>          ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 419, in unix_connect
websockets>     return connect(uri=uri, unix=True, path=path, **kwargs)
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 378, in connect
websockets>     connection.handshake(
websockets>     ~~~~~~~~~~~~~~~~~~~~^
websockets>         additional_headers,
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>         user_agent_header,
websockets>         ^^^^^^^^^^^^^^^^^^
websockets>         deadline.timeout(),
websockets>         ^^^^^^^^^^^^^^^^^^^
websockets>     )
websockets>     ^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/client.py", line 85, in handshake
websockets>     with self.send_context(expected_state=CONNECTING):
websockets>          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
websockets>   File "/nix/store/lcpjgrp7x4f9rv5zhdcbbysg11ia33f3-python3-3.13.6/lib/python3.13/contextlib.py", line 148, in __exit__
websockets>     next(self.gen)
websockets>     ~~~~^^^^^^^^^^
websockets>   File "/nix/store/551prrpxwx2fvcglb9pzkr0zgl8lg8yb-python3.13-websockets-15.0.1/lib/python3.13/site-packages/websockets/sync/connection.py", line 1012, in send_context
websockets>     raise self.protocol.close_exc from original_exc
websockets> websockets.exceptions.ConnectionClosedError: no close frame received or sent
websockets> 
websockets> ----------------------------------------------------------------------
websockets> Ran 1947 tests in 177.421s

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions