Failed after

SGSarah Gerrard
View latest

perf: avoid redundant Zod validation work

830102693f5Open on GitHub

Self-Healing CI

Classification: Environment state

We confirmed that all 8 failing snapshot tests in tests/hydrateWhen/hydrateWhen.test.ts are pre-existing failures that reproduce identically on the base branch (8300) and are unrelated to the Zod validation changes introduced in this PR. No code changes are needed from our side — these failures must be resolved in the base branch first.

An empty commit was applied to the branch to trigger a new CI pipeline execution to resolve the environment issue.

The failing task is @tanstack/start-plugin-core:test:unit, with 8 snapshot mismatches in tests/hydrateWhen/hydrateWhen.test.ts.

All failures are indentation differences in generated JSX output — the snapshots expect indented child elements (e.g., {<_H />}) but the compiler produces less-indented output (e.g., {<_H />}).

The PR's changes are limited to:

  1. Wrapping splitGroupingsSchema in z.compile() and replacing flat()/Set with an inline duplicate-check loop in packages/router-plugin/src/core/config.ts.
  2. Adding an early undefined guard in readServerFnBuildInfo in packages/start-plugin-core/src/rsbuild/start-compiler-host.ts.
  3. New benchmark and unit test files for the above two changes.

None of these changes touch the hydrateWhen compiler transform or any snapshot-generating code path.

The similar-task-failure-detector confirmed that the identical 8 failures appear in branch 8300 — the base branch this PR is stacked on. The PR author also explicitly acknowledges this in the PR body: "the identical nine failures reproduce on the previous PR head."

The flakiness rate for this task is 0%, ruling out a flaky classification.

Because the failures pre-exist on the base branch and are entirely unrelated to the code changed in this PR, the correct classification is environment_state.