Skip to content

fix: SER 5.0.1 - #128

Merged
sandersonstabo merged 4 commits into
masterfrom
release/5.0.1
Oct 19, 2026
Merged

sandersonstabo merged 4 commits into
masterfrom
release/5.0.1

Conversation

@sandersonstabo

@sandersonstabo sandersonstabo commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Fix: in 5.0.0, the root svelte-effect-runtime entrypoint re-exports effect from the compiler chunk, and compiler/sveltekit-remote-bridge.ts imported node:fs/promises at the top level. vite dev serves packages to the browser unbundled, so any page that loaded the client runtime threw Module "node:fs/promises" has been externalized for browser compatibility. The import is now lazy, the same way the compiler already loads its other Node-only modules. Production builds tree-shook it away, so they were not affected.
  • Regression contract: the packed-artifact boundary test now walks the static import graph of the packed browser entry and fails if it reaches any node: specifier.
  • Conformance in dev and production: test:conformance:browser runs every Playwright scenario against production servers first, then with CONFORMANCE_SERVER_MODE=development against vite dev. Native SvelteKit stays the oracle in both modes. The consumer, minimum-kit and broad lanes all use it, and dev results go to .dist/conformance/development, which CI now also uploads as evidence.
  • Harness fixes the dev lane needed:
    • App servers shut down with SIGTERM (gracefulShutdown), so portless can stop vite dev. Playwright's default hard kill left those servers running.
    • The traffic recorder falls back to the completed body when Chromium refuses to stream a response that has already finished. Dev timing made that race fail intermittently.
    • Browser contracts now also fail on uncaught page errors.
  • Release: all four packages bumped to 5.0.1. Changelog: usebarekey/barekey docs/ser-5.0.1.

Verification

  • Against the unfixed 5.0.0 tarball, the new dev lane fails (live-query page renders "Internal Error") and the packed-graph check names node:fs/promises in chunks/compiler-*.js.
  • With the fix:
    • corepack pnpm run test: 64 files, 842 tests pass.
    • Lint and check pass.
    • test:conformance:browser passes on kit-3-primary in both modes (16 + 16 scenarios).
    • test:conformance:minimum-kit passes on SvelteKit 2.69.0 in both modes.
    • Three back-to-back dev runs were green, with no leftover server processes.

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.


Summary by cubic

Fixes the 5.0.0 browser crash in vite dev where the root svelte-effect-runtime entrypoint re-exported effect from the compiler chunk, which eagerly imported node:fs/promises at the top level. Any page that loaded the client runtime threw Module "node:fs/promises" has been externalized for browser compatibility; production builds were unaffected because tree-shaking removed the import. It is now lazy, matching how the compiler loads its other Node-only modules. All four packages are bumped to 5.0.1.

Testing

  • Playwright conformance now runs every scenario against production servers and then against vite dev (CONFORMANCE_SERVER_MODE=development), with development evidence written to .dist/conformance/development.
  • The packed-artifact boundary test walks the browser entry's static import graph and fails on any node: specifier.
  • Harness fixes that dev mode needed: app servers shut down with SIGTERM, traffic recording falls back to completed bodies when Chromium refuses to stream finished responses, browser contracts now also fail on uncaught page errors, and stale portless route locks are cleared before each run so back-to-back runs don't fail to register their servers.

Written for commit ad11bd6. Summary will update on new commits.

View guided diff Turn on auto-fix

sandersonstabo and others added 3 commits October 19, 2026 11:26
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 9240930)
@sandersonstabo
sandersonstabo merged commit ae8215c into master Oct 19, 2026
28 checks passed
@sandersonstabo
sandersonstabo deleted the release/5.0.1 branch October 19, 2026 10:09
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.

1 participant