jroachgolf84 commented on PR #55216:
URL: https://github.com/apache/airflow/pull/55216#issuecomment-3249242645

   Right now, using `@provide_session` seems to be throwing an exception (see 
below). Going to try and figure out the best way around this one!
   
   ```
   2025-09-03 13:16:28 [error] Trigger ID 28 exited with error: 
   Direct database access via the ORM is not allowed in Airflow 3.0 
   [airflow.jobs.triggerer_job_runner] 
   
   error_detail = [
     {
       'exc_type': 'RuntimeError',
       'exc_value': 'Direct database access via the ORM is not allowed in 
Airflow 3.0',
       'exc_notes': [],
       'syntax_error': None,
       'is_cause': False,
       'frames': [
         {
           'filename': 
'/opt/airflow/airflow-core/src/airflow/jobs/triggerer_job_runner.py',
           'lineno': 965,
           'name': 'cleanup_finished_triggers'
         },
         {
           'filename': 
'/opt/airflow/airflow-core/src/airflow/jobs/triggerer_job_runner.py',
           'lineno': 1074,
           'name': 'run_trigger'
         },
         {
           'filename': 
'/opt/airflow/providers/standard/src/airflow/providers/standard/triggers/dummy.py',
           'lineno': 29,
           'name': 'run'
         },
         {
           'filename': '/opt/airflow/airflow-core/src/airflow/triggers/base.py',
           'lineno': 183,
           'name': 'get_watermark'
         },
         {
           'filename': '/opt/airflow/airflow-core/src/airflow/utils/session.py',
           'lineno': 99,
           'name': 'wrapper'
         },
         {
           'filename': '/usr/local/lib/python3.10/contextlib.py',
           'lineno': 135,
           'name': '__enter__'
         },
         {
           'filename': '/opt/airflow/airflow-core/src/airflow/utils/session.py',
           'lineno': 40,
           'name': 'create_session'
         },
         {
           'filename': 
'/opt/airflow/task-sdk/src/airflow/sdk/execution_time/supervisor.py',
           'lineno': 260,
           'name': '__init__'
         }
       ],
       'is_group': False,
       'exceptions': []
     }
   ]
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to