lsst-uk / lasair-lsst

Apache License 2.0
0 stars 0 forks source link

MAX_STATEMENT_TIME #101

Closed RoyWilliams closed 7 months ago

RoyWilliams commented 7 months ago

Please remember to follow the Lasair Pull Request checklist when issuing & reviewing this pull request:

https://lsst-uk.atlassian.net/wiki/spaces/LUSC/pages/2612264961/How+to+do+Pull+Request#STEP-3%3A-Issue-a-Pull-Request-on-Github

CHANGES

gpfrancis commented 7 months ago

This is what the error in Jenkins looks like:

Running in /var/lib/jenkins/workspace/asai_hotfix_max_statement_time/tests/integration/pipeline/filter
[Pipeline] {
[Pipeline] sh
+ python3 test_run_query.py

Running tests...
----------------------------------------------------------------------
EEE
======================================================================
ERROR [0.000s]: test_1_run_query (__main__.RunQueryTest)
Read from the database
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_run_query.py", line 60, in test_1_run_query
    query_results = run_query(querydict, RunQueryTest.msl)
  File "/var/lib/jenkins/workspace/asai_hotfix_max_statement_time/tests/integration/pipeline/filter/../../../../pipeline/filter/run_active_queries.py", line 180, in run_query
    sqlquery_real = ('SET STATEMENT max_statement_time=%d FOR %s LIMIT %d' % (settings.MAX_STATEMENT_TIME, sqlquery_real, limit))
AttributeError: module 'settings' has no attribute 'MAX_STATEMENT_TIME'
...

Maybe add a MAX_STATEMENT_TIME to tests/unit/pipeline/filter/settings.py?