check_d3d12_trace: finish communicate() after killing a timed-out fixture #188

Closed
Andretuta wants to merge 2 commits from upstream-pr/188 into main
Andretuta commented 2026-11-24 02:38:23 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Andretuta on 2026-11-24T02:38:23Z.


Carried over from old PR 9920 by Sunkiller-qc in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch old-pr/9920, exactly that PR's last commit. All carried-over PRs are listed in #17.
Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it.
Sunkiller-qc: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one.


Original description (mentions and #N references are disabled; the numbers refer to the old repository):

Thanks for 433edaa. The subprocess docs recommend finishing with communicate() after killing a timed-out child so the pipes are drained. The call has a limit so a stray process holding the pipes can't stretch the timeout.

Not run on my side; tests/test_check_d3d12_trace.py should cover it.

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5465041381 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/188). Originally posted by [Andretuta](https://github.com/Andretuta) on 2026-11-24T02:38:23Z. --- > Carried over from **old PR 9920** by `Sunkiller-qc` in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch `old-pr/9920`, exactly that PR's last commit. All carried-over PRs are listed in #17. > Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it. > `Sunkiller-qc`: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one. --- Original description (mentions and `#N` references are disabled; the numbers refer to the old repository): Thanks for 433edaa. The subprocess docs recommend finishing with communicate() after killing a timed-out child so the pipes are drained. The call has a limit so a stray process holding the pipes can't stretch the timeout. Not run on my side; `tests/test_check_d3d12_trace.py` should cover it.
sodove commented 2026-11-24 06:30:38 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by sodove on 2026-11-24T06:30:38Z.


I compared current main at 8f481cf16f and this PR at cc2e281959 on native Windows 11 build 26100 with Python 3.12.10. I ran two direct fixtures without a runner, with a two-second timeout. In both cases the descendant inherited stdout and stderr. I opened a Windows process handle before letting the fixture proceed so I could check whether the descendant was still running.

Fixture Current main PR head
Fixture and descendant both keep running Timeout after 7.11 s, descendant still running at return Timeout after 2.16 s, descendant verified exited
Fixture exits zero with one synthetic trace entry while descendant holds output open False timeout after 7.08 s Trace returned in 0.06 s while the descendant was still running

The synthetic descendant had a seven-second fallback and a release signal for cleanup. The stock runner tests also passed on the PR head, with three passed and the POSIX-only process-group test skipped.

Synthetic processes only. AI-assisted verification.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7124007528 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/188#issuecomment-7124007528). Originally posted by [sodove](https://github.com/sodove) on 2026-11-24T06:30:38Z. --- I compared current main at 8f481cf16f261c7f37458aeb45e8f4e19994146d and this PR at cc2e28195926db2cfdc2ea9a3f3824f8282e7f54 on native Windows 11 build 26100 with Python 3.12.10. I ran two direct fixtures without a runner, with a two-second timeout. In both cases the descendant inherited stdout and stderr. I opened a Windows process handle before letting the fixture proceed so I could check whether the descendant was still running. | Fixture | Current main | PR head | | --- | --- | --- | | Fixture and descendant both keep running | Timeout after 7.11 s, descendant still running at return | Timeout after 2.16 s, descendant verified exited | | Fixture exits zero with one synthetic trace entry while descendant holds output open | False timeout after 7.08 s | Trace returned in 0.06 s while the descendant was still running | The synthetic descendant had a seven-second fallback and a release signal for cleanup. The stock runner tests also passed on the PR head, with three passed and the POSIX-only process-group test skipped. Synthetic processes only. AI-assisted verification.
fin-github commented 2026-11-24 21:58:24 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fin-github on 2026-11-24T21:58:24Z.


Taken over in #1330: the same commits cherry-picked onto current main with -x, original author kept, tests rerun there (they still fail on main without the change). The draft can be closed as #17 describes. AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7145633106 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/188#issuecomment-7145633106). Originally posted by [fin-github](https://github.com/fin-github) on 2026-11-24T21:58:24Z. --- Taken over in #1330: the same commits cherry-picked onto current `main` with `-x`, original author kept, tests rerun there (they still fail on `main` without the change). The draft can be closed as #17 describes. AI-assisted (Claude Code).
Andretuta commented 2026-11-27 04:02:02 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Andretuta on 2026-11-27T04:02:02Z.


Closing carried-over draft: taken over in #1330 (OLD-9920).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7209464760 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/188#issuecomment-7209464760). Originally posted by [Andretuta](https://github.com/Andretuta) on 2026-11-27T04:02:02Z. --- Closing carried-over draft: taken over in #1330 (OLD-9920).

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
ProjectLeonida/mandy!188
No description provided.