Control: back-to-back Windows bridge clients fail with EINVAL #481
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/renderer
area/saves
area/upscaling
beanstalk: approved @ 1697603
beanstalk: approved @ 2c5a62e
beanstalk: approved @ 4fd82b7
beanstalk: approved @ 64d6d09
beanstalk: approved @ 6f91fae
beanstalk: approved @ 70a78f9
beanstalk: approved @ 8015c9a
beanstalk: approved @ 8d361dc
beanstalk: approved @ 9d8356e
beanstalk: approved @ abf2227
beanstalk: approved @ d82f202
beanstalk: approved @ e5f1e40
beanstalk: approved @ ee8ab5f
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
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
testing wanted
ci: approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot#481
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
On main9c9d69ed, native Windows Python3.14.7 repeatedly fails tests/test_oot_state_tap.py when socket_cases opens four clients back-to-back. The third Bridge construction fails at scripts/longshot_ctl.py:87, open(name, "r+b", buffering=0), with OSError errno22 / Invalid argument. The failure then becomes "no game listens" although the authored server is running.
The constructor retries only an exception whose winerror is231 (ERROR_PIPE_BUSY). The server creates one listener and replaces it after accepting. A transient busy-pipe race is a hypothesis; the current exception does not retain a Win32 error, so errno22 alone is not sufficient proof. Blanket retry of EINVAL would also hide unrelated errors and is not proposed.
Reproduction: native Windows, llvm-mingw and Python3.14.7, python -I -B tests/run_all.py test_oot_state_tap. Both a full suite and a fresh focused run failed in the same connection sequence. This uses the project's authored game-free fixture, no game files.
Claimed for bounded diagnosis, then a focused production-client fix if a real named-pipe fixture confirms the cause. Preserve missing/access-denied behavior and the existing connection deadline. PR457 handles a POSIX fixture race and explicitly leaves Windows unchanged; no matching open PR was found. The Matrix broadcast is queued for the next allowed hourly window; no force post.
Priority: S3 contributor/control-client reliability defect; confidence1.0 for the reproduced failure, causal hypothesis pending. Affected reach is unmeasured; no player-impact score is assigned.
Confirmed with a real held pipe: CRT open reports errno22 without winerror, while native CreateFileW returns231. Ready PR494 retries only that busy code within the deadline. Two interleaved held-pipe pairs fail on main and pass here; five native methods, the original state-tap check and live actual-game status interoperability pass. Missing/access-denied behavior and all remaining gaps are documented; no blanket EINVAL retry.