ci: add PR build/test guard#294
Merged
Merged
Conversation
Runs npm ci + type-check + test + build on every PR to main, mirroring the Pages deploy. Catches a broken build, failing tests, or a platform-incomplete package-lock.json before merge rather than on the post-merge production deploy (the failure mode behind #291/#292). Co-Authored-By: Claude Opus 4.8 (1M context) <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.
Why
The
#290 → #291 → #292saga happened because nothing validated the build before merge — a platform-incompletepackage-lock.jsononly blew up on the production Pages deploy, after merge. This adds a pre-merge gate so that class of failure is caught on the PR.What it does
A
CIworkflow on every PR tomainthat runs the same steps as the deploy, onubuntu-latest/ node 20:npm ci— strict install; fails fast if the lockfile is out of sync or missing the linux-x64 native binaries (npm/cli#4828), exactly the bug that broke the deploy twicenpm run type-checknpm testnpm run buildEffect
Future PRs that touch dependencies or source can't reach a green-to-merge state with a broken build/tests/lockfile — the failure surfaces on the PR instead of taking down the post-merge deploy. The live site is never the place we discover a bad lockfile.
🤖 Generated with Claude Code