Repository navigation
ci: run the engines check's npx outside the checkout - #10
Merged
Merged
Conversation
After `pnpm install`, a semver in node_modules (a transitive one, with no root bin link) shadows the package npx would fetch, and the step fails with "semver: not found". This repo has no semver in its tree today, so the check passes, but the first dependency that brings one would break it (it did in agentchat-mcp). The range is read in the checkout and npx runs in $RUNNER_TEMP.
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.
What changes
A CI-only follow-up to #9. Nothing changes for users.
The step that checks
engines.nodeadmits each Node version runsnpx -y semver@7.7.4. Afterpnpm install, if asemverpackage is already somewhere innode_modules(a transitive one, with no root bin link), it shadows the package npx would fetch, and the step fails withsemver: not found. This repo has nosemverin its tree today, so #9's check passes. It would break the day a dependency brings one in, which is what happened in agentchat-mcp#29. The range is now read in the checkout, and npx runs in$RUNNER_TEMP.Verification
semver@7.7.4in its tree) on Node 26.13.1. Run in the checkout, it fails with "semver: command not found" (exit 127). Run from another directory, it prints26.13.1for>=22.0.0(exit 0) and exits 1 for>=22.0.0 <23. CI on this PR runs the step on Node 22, 24 and 26 on all three OSes.Risk and rollback
CI only. Rollback: revert this PR.