fix(ci): restore test.yml on main — hashFiles() is illegal in a job-level if: (3 sites) - #2449
Conversation
…evel if Same defect as deploy.yml (#2444, and #2448 porting it to main), but test.yml has it in three places — unit-tests, integration-tests and security-tests each carry: if: hashFiles('packages/shared/package.json') != '' hashFiles() is only available in `jobs.<job_id>.steps.*`, never in a job-level `if:`, so GitHub rejects the whole file at startup and creates zero jobs. Impact is larger here than for deploy.yml: test.yml is main's entire test workflow — Unit Tests, Integration Tests, Security Tests, Coverage Gate, E2E, Type Check and the Merge Gate. While the file fails to parse, none of them run for main-based branches. The workflow looks healthy in aggregate only because most active branches are playground-based, and playground already carries a fixed copy. Ported surgically rather than by copying playground's file, which also: - adds `playground` to the push/PR branch triggers, and - replaces `pnpm run build` (plus its NEXT_PUBLIC_* env) with `pnpm --filter app exec tsc --noEmit` Neither belongs on main — the second would swap a real build for a typecheck and weaken the gate. Only the three existing guards are converted; the e2e job is left unguarded exactly as main has it. Verified: actionlint reports 3 hashFiles context errors on main and 0 here; build step, env and branch triggers are untouched. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reached
Next review available in: 48 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…pp errors
Restoring test.yml (previous commit) runs the e2e suite for the first time
since 2026-05-15. Result: 56 passed, 5 skipped, 1 failed.
The single failure is "Homepage has no console errors", and neither console
error is an app defect — both are third-party analytics that only work on a
real deployment:
- cloudflareinsights.com/cdn-cgi/rum — blocked by CORS from localhost:3000
- /_vercel/insights/script.js — 404s to an HTML page, so strict MIME
checking refuses to execute it
collectConsoleErrors already filters exactly this class of environment noise
(Privy, Supabase, WalletConnect, Sentry, hydration warnings...). These two
belong in that list; they were simply never reachable while the workflow could
not start.
Verified by extracting the 31 filter patterns from the real source and applying
them to the two strings CI actually produced: both are filtered, while genuine
app errors (TypeError/ReferenceError/invalid public key) are still reported, so
the assertion keeps its teeth.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Outcome: the predicted e2e failure happened, and is fixed — full greenI flagged above that The one failure was
Verified the filter keeps its teeth: extracted all 31 patterns from the real source and Current state — all green
That Merge Gate pass is the first on a main-targeting PR since 2026-05-15. Scope note: this PR now carries two commits — the workflow port ( |
Correction: scoping the real gap — narrower than my summary impliedThe PR body is accurate about
The load-bearing detail I initially got wrong: playground's So on main, What this changesThe genuine, non-overlapping loss is E2E (8 spec files, 57 tests once green) plus the Merge Also worth knowing for this PR's valueEven with this merged, Unit / Integration / Security still skip on main, because |
Same defect as deploy.yml, bigger blast radius
ecef0545(#2164, 2026-05-15) added this guard to bothdeploy.ymlandtest.yml.#2444 fixed deploy.yml on
playground; #2448 ports that tomain. This PR is test.yml,which carries the same bug in three places —
unit-tests,integration-testsandsecurity-tests:hashFiles()is only available injobs.<job_id>.steps.*, never in a job-levelif:, soGitHub rejects the file at startup and creates zero jobs.
Why this matters more than deploy.yml
test.ymlis main's entire test workflow: Unit Tests, Integration Tests, Security Tests,Coverage Gate, E2E Tests, Type Check and the ✅ Merge Gate. While the file fails to parse,
none of them run for main — every
mainrun is a startup failure, 1540 runs deep.The workflow looks healthy in aggregate (2350 lifetime successes, 82/100 recent) purely
because most active branches are
playground-based, and playground already carries a fixedcopy. Filtering to
branch=mainshows nothing but failures.This also explains a confusing symptom: a startup failure can't read
on:, so GitHubattributed bogus
test.ymlruns to pushes on branches thatbranches: [main]should haveexcluded entirely.
Ported surgically, not copied
playground's
test.ymlis fixed but also carries changes that must not come to main:playgroundto the push/PR branch triggerspnpm run build(and itsNEXT_PUBLIC_*env) withpnpm --filter app exec tsc --noEmit— swapping a real build for a typecheck, weakening the gateSo I converted only the three existing guards and added the
detect-packagesjob. Branchtriggers, the build step and its env are untouched, and the
e2e-testsjob is left unguardedexactly as main has it (playground adds a guard there; that's a playground behaviour choice).
What to expect when this runs
packages/is not tracked in this repo, sodetect-packagesreportshas_packages=falseandunit-tests/integration-tests/security-testsskip — which is the guard's originalintent.
merge-gatealready handles that correctly:coverage-checkneeds the skipped jobs and has noalways(), so it skips too.Flagging honestly:
e2e-testsandtype-checkare unguarded and will therefore executefor the first time since 2026-05-15. If they fail, that is ~2 months of latent breakage
becoming visible — not a regression introduced here. I would rather surface that than keep it
hidden behind a workflow that never starts. See the checks on this PR for the real answer.
🤖 Generated with Claude Code