Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove useless logging line #25347

Merged
merged 3 commits into from Jul 27, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 6 additions & 3 deletions airflow/models/dagrun.py
Expand Up @@ -728,9 +728,12 @@ def _filter_tis_and_exclude_removed(dag: "DAG", tis: List[TI]) -> Iterable[TI]:
try:
ti.task = dag.get_task(ti.task_id)
except TaskNotFound:
self.log.error("Failed to get task for ti %s. Marking it as removed.", ti)
ti.state = State.REMOVED
session.flush()
if ti.state == State.REMOVED:
pass # ti has already been removed, just ignore it
else:
Jorricks marked this conversation as resolved.
Show resolved Hide resolved
self.log.error("Failed to get task for ti %s. Marking it as removed.", ti)
ti.state = State.REMOVED
session.flush()
else:
yield ti

Expand Down