Skip to content

[vite-plugin] Preserve Worker response status text in v1 - #16493

Merged
petebacondarwin merged 1 commit into
codex/vite-v1-backport-16476from
codex/vite-v1-backport-16453
Oct 28, 2026
Merged

petebacondarwin merged 1 commit into
codex/vite-v1-backport-16476from
codex/vite-v1-backport-16453

Conversation

@petebacondarwin

@petebacondarwin petebacondarwin commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Backports #16453 to Vite plugin v1.

The shared HTTP adapter currently replaces Worker response status text with Node defaults in both dev and preview. Pin the published @remix-run/node-fetch-server 1.0.0 release, regenerate the lockfile with pnpm 10.33.0, and retain the original regression cases for custom, empty, and omitted status text. V1 previously pinned 0.8.1, so this is an independently useful remaining fix.

Stacked on #16480; its earlier Undici/runtime versions are preserved. The unpublished October 23 runtime draft remains above the published-dependency fixes.

Validation: pnpm build, pnpm check (including types), pnpm test:ci, and retained fixtures pass with Node 22.22.1 / pnpm 10.33.0. The HTTP tests exercise the plugin's actual request handler over a local socket. The WebSocket playground passes all 4 dev and 4 preview tests.


  • Tests
    • Tests included/updated
    • Automated tests not possible - manual testing has been completed as follows:
    • Additional testing not necessary because:
  • Public documentation
    • Cloudflare docs PR(s):
    • Documentation not necessary because: restores the existing HTTP response semantics in dev and preview.

Note

This is a contribution from an AI agent: Codex.


Devin Review

@changeset-bot

changeset-bot Bot commented Oct 26, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 3994dcc

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@cloudflare/vite-plugin Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@petebacondarwin

Copy link
Copy Markdown
Contributor Author

@james-elicx (recorded author of #16453) and @petebacondarwin (verified human ant-core approver), could you please check this Vite plugin v1 backport and approve it if it looks good?

V1 uses the same shared HTTP adapter for dev and preview. This independently upgrades its exact 0.8.1 pin to the published 1.0.0 release and retains the original custom/empty/omitted status-text regressions. Earlier #16480 supplies the retained Undici upgrade; those pins are preserved. Build, checks/types, retained tests/fixtures and the WebSocket dev/preview playground pass.

@workers-devprod
workers-devprod requested review from a team and cjol and removed request for a team October 26, 2026 14:06
@workers-devprod

workers-devprod commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Codeowners approval required for this PR:

  • ✅ @cloudflare/wrangler

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@clanky-the-clanker

Copy link
Copy Markdown

✅ Approved — No issues found. The pull request pins @remix-run/node-fetch-server to an exact version, adds regression tests that exercise the real request handler, and includes a patch changeset for the plugin.

The decision is advisory: this comment never approves, blocks or requests changes on the pull request.


✅ All checks passed

📋 Code Quality: ✅ LGTM

The dependency change is one line. It pins @remix-run/node-fetch-server to exactly 1.0.0, which matches the repository's exact-version policy for public dependencies.

The new parameterized tests run the plugin's createRequestHandler against a real local HTTP server. They cover three cases: custom status text, empty status text, and status text that was never set. They use the test-context expect and reuse the existing httpServer/port cleanup.

This review could not confirm that the 1.0.0 release still exports createHeaders and sendResponse, which the plugin imports, because dependency sources are not in the snapshot. The pull request description says build, type checking and tests pass with 1.0.0.


📝 Documentation: ✅ LGTM

The changeset .changeset/vite-plugin-preserve-status-text.md marks @cloudflare/vite-plugin as a patch. It clearly describes the change users will see: custom and empty statusText are now preserved in dev and preview.


Reviewed commit: 3994dccb

@pkg-pr-new

pkg-pr-new Bot commented Oct 26, 2026

Copy link
Copy Markdown
npm i https://pkg.pr.new/@cloudflare/vite-plugin@16493

commit: 3994dcc

@workers-devprod workers-devprod left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codeowners reviews satisfied

@petebacondarwin
petebacondarwin removed this pull request from stack #16505 October 28, 2026 11:08
@petebacondarwin
petebacondarwin merged commit 4ce6176 into vite-plugin-v1 Oct 28, 2026
42 of 43 checks passed
@petebacondarwin
petebacondarwin deleted the codex/vite-v1-backport-16453 branch October 28, 2026 11:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants