Revert "fix(core): transform EmDash/adapter/plugin packages inline in CF dev (#1359)"#1363
Conversation
|
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
docs | 7296208 | Jun 05 2026, 01:58 PM |
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ❌ Deployment failed View logs |
emdash-playground | 7296208 | Jun 05 2026, 01:59 PM |
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
emdash-demo-cache | 7296208 | Jun 05 2026, 01:59 PM |
There was a problem hiding this comment.
This is a clean, complete revert of #1359 (commit c9d0724). The PR removes the inlinePackages optimization that caused deterministic failures in the E2E Cloudflare lane, restoring the repository to the previously-green state at 4fb27752.
I verified the revert is exact:
git diff 4fb27752..HEAD -- packages/core/src/astro/integration/vite-config.tsproduces no output, confirming the file is byte-for-byte identical to its pre-#1359 state.- Both #1359 and this revert touch exactly 2 files (the changeset +
vite-config.ts), and the line counts of the forward and reverse diffs match (103 lines each).
The removed inlinePackages logic (helper functions packageNameFromSpecifier / collectPluginPackages, the inlinePackages array, and its injection into ssr.noExternal and ssr.optimizeDeps.exclude) is all faithfully restored. The stray "astro/zod" entry added by #1359 is correctly removed.
No AGENTS.md issues: no new code to localize, no SQL, no API routes, no database changes, no tests needed (revert), and removing the unreleased changeset is the right call. No findings.
@emdash-cms/admin
@emdash-cms/auth
@emdash-cms/auth-atproto
@emdash-cms/blocks
@emdash-cms/cloudflare
@emdash-cms/contentful-to-portable-text
emdash
create-emdash
@emdash-cms/gutenberg-to-portable-text
@emdash-cms/plugin-cli
@emdash-cms/plugin-types
@emdash-cms/registry-client
@emdash-cms/registry-lexicons
@emdash-cms/sandbox-workerd
@emdash-cms/x402
@emdash-cms/plugin-ai-moderation
@emdash-cms/plugin-atproto
@emdash-cms/plugin-audit-log
@emdash-cms/plugin-color
@emdash-cms/plugin-embeds
@emdash-cms/plugin-field-kit
@emdash-cms/plugin-forms
@emdash-cms/plugin-webhook-notifier
commit: |
There was a problem hiding this comment.
Pull request overview
This PR reverts PR #1359 (commit c9d07241) to restore the previously-green main behavior after Cloudflare E2E started failing deterministically. The revert removes the dev-only Vite SSR inline-transform configuration for EmDash/core + Cloudflare adapter + plugins, and drops the accompanying changeset so the reverted behavior won’t be released.
Changes:
- Remove
inlinePackages/plugin-package collection logic that altered Cloudflare dev SSRnoExternal+ssr.optimizeDeps.exclude. - Remove the additional
ssr.optimizeDeps.includeentry (astro/zod) introduced in #1359. - Delete the changeset that would have shipped the reverted behavior.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
packages/core/src/astro/integration/vite-config.ts |
Reverts Cloudflare-dev SSR dependency optimization tweaks (inline package transforms and related optimizeDeps changes). |
.changeset/fix-cf-dev-inline-plugins.md |
Removes the unreleased changeset associated with the reverted functionality. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
What does this PR do?
Reverts #1359 (commit c9d0724), which broke the E2E Cloudflare lane on
mainand the release PR (#1360).mainwas green at4fb27752and went red onc9d07241(the #1359 merge). The E2E Cloudflare (1/8) shard fails deterministically (confirmed across two runs) on three tests, while the only Node-lane failure (aninvite-flowflake) recovered on re-run:api-tokens.spec.ts:22/:137—strict mode violation: locator('text=dev-bypass-token') resolved to 2 elementsaccessibility.spec.ts:28— Login Pageh1"Sign in"not found (15s timeout)Why #1359 caused it
#1359 added
emdash,@emdash-cms/cloudflare, and configured plugin packages tossr.optimizeDeps.exclude+noExternal(dev only), so Vite transforms them inline instead of pre-bundling. Under the workerd dev runtime used by the CF e2e fixture this regresses the admin/login route (slow cold compile and/or SSR error): the loginh1never appears within 15s, and global-setup'sdev-bypass?token=1(guarded bywaitForOkwith a 10s per-attempt timeout) times out client-side after the server has already created the token, retries, and creates a seconddev-bypass-token— hence the duplicate.The fix itself is still wanted (it resolves the dependency-optimize reload cascade on registry installs, the original report). It needs to be redone with verification against the CF e2e fixture (
EMDASH_E2E_TARGET=cloudflare), which I did not run for #1359 — my manual verification used route requests, not the e2e suite. Reverting unblocks the release; I'll reopen a corrected PR.Type of change
Checklist
pnpm typecheckpasses (pure revert to a previously-green commit)pnpm lintpassespnpm test— relying on CI; this restores the previously-green treepnpm format— n/a, revert onlyAI-generated code disclosure