Repository navigation
fix(action): write store bin dirs to GITHUB_PATH in reverse order - #1356
Merged
Merged
Conversation
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.
Summary
The direnv-mode
setup-devkit-toolchainstep extracts the consumer dev-shell$PATH, filters the/nix/storebin dirs, and wrote them toGITHUB_PATHhighest-priority-first. The Actions runner prepends everyGITHUB_PATHline in file order (the prepend list is joined reversed when composing the next step's PATH), so following steps ran with the dev-shell PATH exactly reversed.Invisible while one tool means one store path — which is why every Python/TS consumer stayed green — but fatal for a stdenv toolchain: raw
gccshadowedgcc-wrapper(likewisebinutils) and C builds failed with the unwrapped-compiler signatureld.bfd: cannot find Scrt1.o/cannot find -lc, while the same build was green locally undernix develop. First live hit: vig-os/h5v#2 (vendored HDF5 cmake build, run 31160809242).The store bin dirs are now piped through
tacbefore the write, so the runner's per-line prepend rebuilds the dev-shell order verbatim. Bare-mode's single-lineuv tool dir --binwrite is unaffected; the env-forward denylist is untouched (that's #1353).Test plan
test_devshell_path_priority_survives_github_path: the fake dev-shell PATH now carries agcc-wrapper-13/bin→gcc-13/binpair; a_runner_pathhelper replays the runner's per-line prepend and the test asserts the wrapper precedes the raw compiler AND the full store-bin subsequence equals the dev-shell order — semantics-pinned, no coupling totac. RED on the old code with the whole order inverted, exactly the issue shape.tests/test_setup_toolchain_env.py: 25/25 green (verified independently by reviewer).tests/bats/init-workspace.bats(renders + actionlints the scaffold): 280/280 green.prek run --all-filesgreen.Refs: #1351