fix(dev): proc_start sends no Ctrl+C on Windows, so run_all.py runs to the end #2304
No reviewers
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/renderer
area/saves
area/tooling
area/upscaling
beanstalk: approved
beanstalk: failed
beanstalk: needs approval
beanstalk: running
beanstalk: tested
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
risk
high
risk
low
risk
medium
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!2304
Loading…
Reference in a new issue
No description provided.
Delete branch "mmkzero/Longshot:fix/windows-proc-start-ctrl-c"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
On Windows,
tests/run_all.pydied part-way through without a word: no summary, no exit code, and the shell running itwent too.
test_job_queue.pypatchescommon.WINDOWSoff to check the Linux paths, which tookprocs.proc_startto itsos.kill(pid, 0)fallback. On Windows signal 0 isCTRL_C_EVENT, so that call sent a Ctrl+C to every process of theconsole.
proc_startnow checks the real platform before that fallback and reads the start time the Windows way.To see it on main:
python -I -B tests/run_all.py test_job_queuein a console on Windows; run_all.py and its shell end.Read first:
proc_startinscripts/devtools/procs.py, and the newWindowsConsolecheck intests/test_job_queue.py.Fixes #2303
Testing
Tested: Windows 11, Ryzen 9 7940HS, the builder's Python and llvm-mingw (
dev.py env). The new check fails on main3 of 3 runs (
'ctrl-c' != 'quiet') and passes here 3 of 3;tests/test_job_queue.pypasses whole (26 tests, 5 skippedon Windows). The whole suite now runs to the end: 890 passed, 17 failed, 50 skipped in 333 s. The 17 fail on main too,
in the same environment (17 of 17): test_auto_handheld, test_crash_dialog, test_dev_ab, test_dev_build,
test_dev_migrate, test_dev_packs, test_finish_output, test_game_menu_mouse_buttons, test_input_movie,
test_linux_preflight, test_longshot_ctl, test_pads_after_menu, test_perf_report, test_pipeline_state_computes,
test_sampler_admission, test_saveload_warm_cache, test_sdiv_overflow.
Linux (Arch on WSL2, kernel 6.6.87, Python 3.14.10):
python -I -B tests/test_job_queue.pypasses here (26 tests, 6skipped, the new check among them) as on main (25 tests, 5 skipped); the PosixTree checks all pass.
Still to test: None
Measurements
Verdict: the suite runs to the end on Windows; the new check fails on main and passes here.
Setup: Windows 11, Ryzen 9 7940HS, 16 checks at once;
tests/run_all.pystarted from a console, as a player orcontributor would.
753fb5af7e66aa6etests/run_all.py, whole suitetest_job_queue.py WindowsConsoleRisks
Windows only (
os.name == "nt"), and only where a test patchescommon.WINDOWSoff: Linux and macOS take the samepaths as before. Nothing changes for players. A revert is enough.
Checklist
Ready for review
main; the title is a Conventional Commit.mise run testpasses (any failure that also fails onmainis named).main, or Measurements says why there is nothing to measure.third_party/untouched; nothing GPL-incompatible.When it applies
mainand passes here.Ready to merge
main, measured again or a comment says why the numbers still hold.WIP: fix(dev): proc_start sends no Ctrl+C on Windows, so run_all.py runs to the endto fix(dev): proc_start sends no Ctrl+C on Windows, so run_all.py runs to the end