Skip to content

[pull] canary from vercel:canary - #2096

Merged
pull[bot] merged 3 commits into
MLH-Fellowship:canaryfrom
vercel:canary
Sep 29, 2026
Merged

pull[bot] merged 3 commits into
MLH-Fellowship:canaryfrom
vercel:canary

Conversation

@pull

@pull pull Bot commented Sep 29, 2026 •

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

jamiboym and others added 3 commits September 29, 2026 05:47
## Summary

Enable deploy testing for five suites: middleware page extensions, mixed
proxy page extensions, false aliases, CSS module ordering, and
conflicting service worker registrations. Their deploy-mode assertions
check served responses, browser-rendered styles, or a specific remote
build failure.

## Verification

The retained changes passed [Turbopack deploy
CI](https://github.com/vercel/next.js/actions/runs/36188078111) at
`293d58d`, including cache-components jobs. Webpack deploy behavior
remains unverified.

Local formatting and ESLint checks passed. The four restored files match
the PR base exactly, and the five retained files are unchanged. A full
local bootstrap could not complete because this worktree lacks
package-level dependencies (`microbundle`).

<!-- NEXT_JS_LLM -->

---------

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
## Summary

Set the correct HTTP status and redirect location when a prerendered
page throws `notFound()`, `unauthorized()`, `forbidden()`, `redirect()`,
or `permanentRedirect()` inside Suspense. Preserve the prerendered
layout and Suspense fallback so the client can recover at the
appropriate error boundary.

Redirects take precedence over HTTP access fallbacks. Among access
fallbacks, or among redirects, the first observed error wins. The HTML
error callback and prerender recovery catch share this rule, so a later
fatal not-found error cannot overwrite an already captured redirect. The
catch still classifies its own error independently of the selected
response.

Request-time streaming behavior is unchanged. A dynamic not-found after
`connection()` can still return 200. The custom error UI itself is not
prerendered and remains a follow-up.

Related:
[NAR-435](https://linear.app/vercel/issue/NAR-435/set-status-code-on-prerendered-output-whenever-notfound-or-redirect).

## Verification

- All 57 production Turbopack tests pass with Cache Components enabled
and disabled, with `__NEXT_EXPERIMENTAL_STRICT_ROUTE_TYPES=true`. This
includes 44 ordered-error cases covering sibling Suspense boundaries and
the outer recovery catch, status/location consistency, and preserved
layout/fallback HTML.
- Removing the precedence fix causes 22 regression cases to fail.
- All 36 existing on-demand prerender recovery tests pass with Cache
Components enabled: `NEXT_SKIP_ISOLATE=1 NEXT_TELEMETRY_DISABLED=1
__NEXT_EXPERIMENTAL_STRICT_ROUTE_TYPES=true __NEXT_CACHE_COMPONENTS=true
pnpm test-start-turbo
test/e2e/app-dir/on-demand-prerender-error-boundary/on-demand-prerender-error-boundary.test.ts`.
- Dev gate verified: all 57 tests are skipped.
- Local tests used the installed SWC canary.38 binary with Next.js
canary.42 and emitted a version mismatch warning. Deploy mode was not
run locally.

<!-- NEXT_JS_LLM -->

---------

Co-authored-by: Jamiboy Mohammad <2085704+jamiboym@users.noreply.github.com>
## Summary

To measure how client component loading affects HTML render performance,
replace telemetry based on process-global counters and incoming
request-body completion. Those boundaries mixed overlapping renders and
measured a lifecycle unrelated to HTML production.

Scope the counters and reporting context to each HTML-producing render.
Start tracking before SSR, finish dynamic measurements at React
readiness (Node `onAllReady` / Web `allReady`), and finish prerendering
when the prerender operation returns. Preparation, action execution, and
dedicated Flight rendering do not start tracking. DATA-only resumes
finish tracking locally without waiting for output; an empty tracker
emits no span. HTML rendered after a form action is still measured.

Already-started loads may settle and report afterward without keeping
the response open. Preserve the first-write performance snapshot, but
remove metrics stream wrapping and binding. This advances the larger
effort to remove req/res lifecycle assumptions from App Router rendering
without adding telemetry to `after()`.

Behavioral tests cover overlapping renders in both completion orders,
HTML after a form POST, enhanced actions that only produce Flight, and
HTML readiness while unused Flight content remains blocked.

## Verification

- Confirmed both new boundary regressions failed before the runtime
change.
- Five behavioral metrics cases pass in development and production with
both Turbopack and Webpack.
- Full production Turbopack instrumentation suite: 109 passed, 13
existing skips.
- Focused logger/response-piping units: 11 passed. Full repository
build, package/root types, scoped Prettier, ESLint, and diff checks
pass.
- A broader unit run passed 3,065 tests but hit three macOS `/var`
versus `/private/var` assertions in unchanged TypeScript CLI tests.

Existing Node response-disconnect propagation to upstream SSR is
unchanged; this PR does not claim to fix cancellation.

<!-- NEXT_JS_LLM -->
@pull pull Bot locked and limited conversation to collaborators Sep 29, 2026
@pull pull Bot added the ⤵️ pull label Sep 29, 2026
@pull
pull Bot merged commit bc8bf60 into MLH-Fellowship:canary Sep 29, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants