o-nikolas commented on PR #46944:
URL: https://github.com/apache/airflow/pull/46944#issuecomment-2673252201
Getting the tests to ignore the deprecation warning at the right time has
proven very annoying/tricky.
The last stubborn one is related to one instances of the warning not being
thrown, but it seems that some underlying failure is actually happening, but
I'm not sure why it's happening on this branch that should be otherwise stable.
And I also cannot produce it locally. From the test failure logs:
```
with pytest.warns(RemovedInAirflow3Warning):
> file_handler.read(ti)
E Failed: DID NOT WARN. No warnings of type (<class
'airflow.exceptions.RemovedInAirflow3Warning'>,) were emitted.
E Emitted warnings: [].
tests/utils/test_log_handlers.py:289: Failed
---------------------------- Captured stdout setup
-----------------------------
[2025-02-21T01:46:21.370+0000] {dagbag.py:588} INFO - Filling up the DagBag
from /dev/null
----------------------------- Captured stdout call
-----------------------------
[2025-02-21T01:46:21.386+0000] {dag.py:3239} INFO - Sync 1 DAGs
[2025-02-21T01:46:21.391+0000] {dag.py:3262} INFO - Creating ORM DAG for
dag_for_testing_multiple_executors
[2025-02-21T01:46:21.397+0000] {dag.py:4180} INFO - Setting next_dagrun for
dag_for_testing_multiple_executors to 2016-01-01T00:00:00+00:00,
run_after=2016-01-02T00:00:00+00:00
[2025-02-21T01:46:21.436+0000] {file_task_handler.py:623} ERROR - Could not
read served logs
Traceback (most recent call last):
File "/opt/airflow/airflow/utils/log/file_task_handler.py", line 599, in
_read_from_logs_server
log_type = LogType.TRIGGER if ti.triggerer_job else LogType.WORKER
File
"/usr/local/lib/python3.9/site-packages/sqlalchemy/ext/associationproxy.py",
line 193, in __get__
return inst.get(obj)
File
"/usr/local/lib/python3.9/site-packages/sqlalchemy/ext/associationproxy.py",
line 575, in get
target = getattr(obj, self.target_collection)
File
"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/attributes.py", line
487, in __get__
return self.impl.get(state, dict_)
File
"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/attributes.py", line
959, in get
value = self._fire_loader_callables(state, key, passive)
File
"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/attributes.py", line
995, in _fire_loader_callables
return self.callable_(state, passive)
File
"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/strategies.py", line
863, in _load_for_state
raise orm_exc.DetachedInstanceError(
sqlalchemy.orm.exc.DetachedInstanceError: Parent instance <TaskInstance at
0x7fe810c4d6d0> is not bound to a Session; lazy load operation of attribute
'trigger' cannot proceed (Background on this error at:
https://sqlalche.me/e/14/bhk3)
```
--
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]