I sometimes get the following error when running a Python query using the OpenSky Python classes.
File "/usr/local/lib/python3.11/site-packages/trino/client.py", line 565, in _process_error
raise exceptions.TrinoExternalError(error, query_id)
trino.exceptions.TrinoExternalError: TrinoExternalError(type=EXTERNAL, name=HIVE_UNKNOWN_ERROR, message="Unable to execute HTTP request: Timeout waiting for connection from pool", query_id=20240621_064019_27191_jtdt5)
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/rherson1/pythoncode/Opensky_history_trino_today.py", line 321, in <module>
vReturnedDataSet= trino.raw_sql(SQLcmd1) # returns aircraft movements in PANDAS structure
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyopensky/trino.py", line 653, in raw_sql
res = self.query(stmt, cached=cached, compress=compress)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyopensky/trino.py", line 172, in query
res = pd.concat(self.process_result(connect.execute(query)))
^^^^^^^^^^^^^^^^^^^^^^
The SQL query I run usually works fine but then for some reason goes through a period of failing. FYI: The query returns around 15k lines from the history table.
Thanks.
Richard.