fix(pr-checks): build-env could not set NODE_OPTIONS, the one variable it was for - #7
Merged
Merged
Conversation
…e it was for The build step wrote every build-env line to $GITHUB_ENV. GitHub refuses a few names there — NODE_OPTIONS among them, because it can inject code into node processes the runner itself spawns — and the step fails outright: Can't store NODE_OPTIONS output parameter using '$GITHUB_ENV' command. That is precisely the variable this input exists to carry. Node sizes its old-space from total system RAM, which lands near 2 GB on the self-hosted pool, and `next build` sits right at that edge — so whether it OOMs depends on which pages a given commit generates rather than on anything being wrong. build-env is now exported into the build step's own shell instead. Process env is not subject to the $GITHUB_ENV denylist, and nothing else needed it: install does not read build-time config, so the two steps are simply ordered. `IFS='=' read -r k v` splits on the FIRST `=` only, so values containing `=` (URLs, base64) survive intact. Verified. Found on kodni.me#172, the first real consumer of this workflow. Why: an input that cannot carry the value it was added for is worse than no input, because callers write it and believe it took effect. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
Found on kodni.me#172, the first real consumer of
pr-checks.The build step wrote every
build-envline to$GITHUB_ENV. GitHub refuses a few names there —NODE_OPTIONSamong them, since it can inject code into node processes the runner itself spawns.That is exactly the variable this input exists to carry. Node sizes its old-space from total system RAM, which lands near 2 GB on the self-hosted pool, and
next buildsits right at that edge — so whether it OOMs depends on which pages a commit generates rather than on anything being wrong.Fix
build-envis exported into the build step's own shell. Process env is not subject to the$GITHUB_ENVdenylist. Nothing else needed it — install does not read build-time config — so the two steps are simply ordered.IFS='=' read -r k vsplits on the first=only, so values containing=(URLs, base64) survive. Verified:After merge
Move
v1, then re-run kodni.me#172.🤖 Generated with Claude Code