Closed Jamucy closed 10 months ago
v1.4.0
Windows 10 Python 3.9
Hi
is not possible to set transportOptions when using tls-client-windows-64.dll with python?
in particular im trying to define the IdleConnectionTimeout but nothing i have tried seems to be working.
sometimes i need to pause for a few min between request but need the connection kept alive for the next request. but atm it doesnt seem possible
TransportOptions = { "DisableKeepAlives": False, "IdleConnTimeout": 0 } requestPayload = { "transportOptions": TransportOptions, "tlsClientIdentifier": "chrome_112", "followRedirects": False, "withoutCookieJar": True, "withDebug": False, "catchPanics": True, "withRandomTLSExtensionOrder": True, "timeoutSeconds": 30, "sessionId": "my-session-id", "proxyUrl": "", "isRotatingProxy": False, "headers": { "accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9", "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36", "accept-encoding": "gzip, deflate, br", "accept-language": "de-DE,de;q=0.9,en-US;q=0.8,en;q=0.7" }, "headerOrder": [ "accept", "user-agent", "accept-encoding", "accept-language" ], "requestUrl": "https://microsoft.com", "requestMethod": "GET", "requestBody": "", "requestCookies": [] } while True: response = request(json.dumps(requestPayload).encode('utf-8')) response_bytes = ctypes.string_at(response) response_string = response_bytes.decode('utf-8') response_object = json.loads(response_string) sleep(120)
@Jamucy you are right. we are missing the options. Will add them in the next version
@Jamucy please check out release 1.5.0
TLS client version
v1.4.0
System information
Windows 10 Python 3.9
Issue description
Hi
is not possible to set transportOptions when using tls-client-windows-64.dll with python?
in particular im trying to define the IdleConnectionTimeout but nothing i have tried seems to be working.
sometimes i need to pause for a few min between request but need the connection kept alive for the next request. but atm it doesnt seem possible
Steps to reproduce / Code Sample