Repository navigation
Conversation
The ZHTW_NO_NETWORK refusal path exits before reading stdin, so writing the fixture races the process exit and can fail with a broken pipe, as seen on the ubuntu-24.04 job. Tolerate only that error kind and fail on any other, so unrelated I/O failures still surface. The assertions on exit status and stderr are what the test verifies.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The ZHTW_NO_NETWORK refusal path exits before reading stdin, so writing the fixture in cli_no_network_env_refuses_verify races the process exit and can fail with a broken pipe (seen on the ubuntu-24.04 job of run 43977152132). The test now ignores the write result and keeps its assertions on exit status and stderr.
Verified locally with make check, plus cargo test --test cli-lint cli_no_network. The race is timing dependent and did not reproduce locally before the fix, so CI is the real confirmation.
Summary by cubic
Fixes a race in
cli_no_network_env_refuses_verifywhere writing the stdin fixture could fail with a broken pipe because the refusal path exits before reading stdin. The test now toleratesBrokenPipewrite errors and fails on any other error kind, keeping its assertions on exit status and stderr. No behavior change tozhtw-mcpitself; only the test was updated.Written for commit d5e7fcd. Summary will update on new commits.