Repository navigation
P-59's trial tests bring their own timeout, and leave HOME empty on macOS - #545
Conversation
…acOS The ReadConfinementTrial tests ran tools/trial_p59_read_confinement.sh with the host's PATH, and the script refuses to start without `timeout`, which macOS keeps only in Homebrew. The stand-in folder now holds a bin/ with a `timeout` that runs its command after the duration, as NarrowedToken's stand-in curl and openssl do, and the tests put it first on PATH. Once the script ran, macOS's own python3 cached the stand-in CLI's bytecode under the empty HOME the test checks, so the stand-in runs with -B. The script is unchanged: a real trial still needs a real `timeout`. Closes #544 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
The stand-in ran whatever followed its first argument, so on Linux CI, where it now stands first on PATH, a malformed duration in the script's calls to `timeout` went unnoticed: with line 212's 180 made 18O, the tests passed. It now exits 125, as GNU timeout does, for a duration that is not whole seconds or no command, and that change to line 212 fails the tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…test holds it The stand-in refused 1.5 and 90s, which GNU timeout runs, and no test held what it refused. It now takes a number with an optional s, m, h or d and refuses anything else, or no command, with 125. A new test runs it on eleven durations and no command, and runs the real timeout in /usr/bin or /bin beside it where there is one, as on Linux CI, so the two must agree. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|



Closes #544.
Since #532, three
ReadConfinementTrialtests failed on macOS underPATH=/usr/bin:/bin. Two things caused it, and a third came from review:timeouton macOS's own PATH.tools/trial_p59_read_confinement.shrefuses to start without one. The stand-in folder now holds abin/timeoutthat runs its command after the duration (execaftershift), asNarrowedToken's stand-incurlandopenssldo, andenvironment(folder)puts thatbin/first on PATH.python3cached the stand-in CLI's bytecode underHOME/Library/Caches/com.apple.python, whichtest_the_engine_configuration_is_judged_by_the_conditionholds empty. The stand-in'sclaudewrapper now runspython3 -B.timeoutin these tests, so it takes what GNUtimeouttakes (a number with an optionals,m,hord) and refuses anything else, or no command, with 125.test_the_stand_in_timeout_runs_what_gnu_timeout_runsholds it on eleven durations, and runs the realtimeoutin/usr/binor/binbeside it where there is one, so on CI the two must agree; on this Mac all eleven agree with Homebrew's coreutils 9.12. With line 212's180made18O,test_each_configuration_is_given_the_read_tools_and_its_own_flagsfails.The script is unchanged: a real trial still needs a real
timeout. Because the stand-in execs, the/proc/<parent>/environa leaking call reads on Linux is now the CLI's own rather than a separatetimeout's; both start with the same environment and marker, so no assertion changes.No record, no rule changed: a test-only change.
Verify
PATH=/usr/bin:/bin python3 -m unittest tests.test_tools.ReadConfinementTrial: 5 tests OK (3 failed before).PATH=/usr/bin:/bin SIM_SEEDS=40 make verifyon an export of5b01bd7: 1569 tests OK (8 expected failures).tools/mutants.py, theP59block), run alone onb9f6ef5: 18 of 18 killed.5b01bd7changes only the stand-in and adds its test.Reviews
88c7e2eb9f6ef588c7e2e88c7e2etests/test_tools.py:8087tests/test_tools.py:8088tests/test_tools.py:8087Bots: Codex reviewed
b9f6ef5with no findings; SonarCloud's gate passed on5b01bd7; CodeRabbit skipped (auto reviews off).Argon: not run (quota), owed; Astra read
88c7e2eas its stand-in.🤖 Generated with Claude Code