You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "DaveT1991 (via GitHub)" <gi...@apache.org> on 2026/04/10 04:52:25 UTC
[PR] Ignore closed DAG processor loggers during log drain [airflow]
DaveT1991 opened a new pull request, #64996:
URL: https://github.com/apache/airflow/pull/64996
## Summary
Prevent DAG processor crashes when late subprocess log events arrive after a DAG file processor's log file handle has already been closed.
`process_log_messages_from_subprocess()` currently forwards every decoded log event directly to each configured logger. During orphan process termination, buffered socket events can still be delivered after the DAG processor has already closed the corresponding BytesLogger file handle, which raises `ValueError: write to closed file` and brings down the whole job.
This change treats that specific closed-file logger error as a dropped late log line instead of letting it propagate, and adds regression coverage for the mixed case where one target logger is already closed while another is still able to receive the message.
Closes #64959
## Testing
- Added regression coverage in `task-sdk/tests/task_sdk/execution_time/test_supervisor.py`
- `git diff --check`
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Ignore closed DAG processor loggers during log drain [airflow]
Posted by "Saddala (via GitHub)" <gi...@apache.org>.
Saddala commented on PR #64996:
URL: https://github.com/apache/airflow/pull/64996#issuecomment-4222339373
Duplicate of #64959 . A fix is being tracked there. PR has been raised on the original issue #64959
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org