trino-python-client icon indicating copy to clipboard operation
trino-python-client copied to clipboard

Enable prepared statements over http.client._MAXLINE limit

Open mdesmet opened this issue 3 years ago • 0 comments

Fixes #148

Headers can become much longer then what is currently suported in Python's http.client. This code patches the header parsing from http.client to be able to parse the headers coming back from the Trino server.

Test is included. when removing the disable_header_limit() in client.py, the test will fail with requests.exceptions.ConnectionError: ('Connection aborted.', LineTooLong('got more than 65536 bytes when reading header line')).

mdesmet avatar Apr 22 '22 13:04 mdesmet