mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-07-27 17:17:25 +02:00
what about this?
This commit is contained in:
parent
6c585b9de8
commit
4b3fd5f833
|
@ -160,7 +160,7 @@ def handle(self):
|
|||
import websockets.sync.server
|
||||
self.request.settimeout(None)
|
||||
protocol = websockets.ServerProtocol()
|
||||
connection = websockets.sync.server.ServerConnection(socket=self.request, protocol=protocol, close_timeout=0)
|
||||
connection = websockets.sync.server.ServerConnection(socket=self.request, protocol=protocol, close_timeout=10)
|
||||
connection.handshake()
|
||||
for message in connection:
|
||||
if message == 'proxy_info':
|
||||
|
@ -241,7 +241,7 @@ def proxy_server(proxy_server_class, request_handler, bind_ip=None, **proxy_serv
|
|||
yield f'{bind_address}:{server_port}'
|
||||
finally:
|
||||
server.shutdown()
|
||||
server.server_close()
|
||||
server_thread.join()
|
||||
|
||||
|
||||
class HTTPProxyTestContext(abc.ABC):
|
||||
|
|
Loading…
Reference in New Issue
Block a user