×

Notice

The forum is in read only mode.

Python Classes

6 months 1 day ago #2747 by Herson
Python Classes was created by Herson
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.
6 months 15 hours ago #2748 by strohmeier
Replied by strohmeier on topic Python Classes
It's a timeout, happens with intense usage.
5 months 4 weeks ago #2750 by Herson
Replied by Herson on topic Python Classes
Thanks.

I appreciate there are a number of BAU background processes that are run throughout the data and night but are there any specific times we should avoid to prevent overloading the platform?
Powered by Kunena Forum
This website uses cookies to offer you the best experience of our services. By using this website you agree to our privacy policy!