You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "potiuk (via GitHub)" <gi...@apache.org> on 2026/10/05 18:14:05 UTC
[PR] Fix flaky Lang-SDK runtime file descriptor test [airflow]
potiuk opened a new pull request, #74288:
URL: https://github.com/apache/airflow/pull/74288
`test_the_runtime_inherits_only_its_standard_streams[fork]` read the runtime's open descriptors as soon as `psutil` reported the process name `sleep`. The kernel renames a process during `execve`, before the dynamic loader opens and closes the shared libraries it loads on the lowest free descriptor, so the test can catch a short-lived fd 3 and fail although nothing was inherited. It failed this way in https://github.com/apache/airflow/actions/runs/37348004406/job/111896084460 (`['0', '1', '2', '3']`) and passed in the other runs of that job around the same time.
The test now waits up to five seconds for the descriptor set to settle before asserting. A descriptor inherited from the Dag processor is never closed by `sleep`, so a real leak still fails the test, and the assertion message now shows what each descriptor points to, which the old failure did not.
I could not reproduce the race locally (the test needs `/proc`); the explanation fits the evidence: only the fast `fork` variant failed, and the real exec path marks every descriptor above 2 close-on-exec before `exec`. `ruff` and `prek` pass on the changed file.
---
##### Was generative AI tooling used to co-author this PR?
- [X] Yes — Claude Code (Claude Opus 5)
Generated-by: Claude Code (Claude Opus 5) following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)
--
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] Fix flaky Lang-SDK runtime file descriptor test [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk merged PR #74288:
URL: https://github.com/apache/airflow/pull/74288
--
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