trinodb / trino-python-client

Python client for Trino
Apache License 2.0
307 stars 150 forks source link

Add support for 'None' on response data #443

Closed avibhstarburst closed 5 months ago

avibhstarburst commented 5 months ago

Description

Add support for 'None' on response data

Non-technical explanation

Release notes

( ) This is not user-visible or docs only and no release notes are required. ( ) Release notes are required, please propose a release note for me. (x) Release notes are required, with the following suggested text:

* Fix possible failures when retrieving query results if the server returns empty data. ({issue}`443`)
hovaesco commented 5 months ago

To write a unit test here please create mock like https://github.com/trinodb/trino-python-client/blob/ca38d2908533d891eedf5ee80f38dbdcfbbdb564/tests/unit/conftest.py#L64 and then see how it's used in tests https://github.com/trinodb/trino-python-client/blob/ca38d2908533d891eedf5ee80f38dbdcfbbdb564/tests/unit/test_client.py#L682