Repository navigation
docs: list the Node.js plugin sandbox in the README - #3430
Conversation
The platform table gave "In-process (safe mode)" as the plugin runtime outside Cloudflare, and the Plugins summary mentioned sandboxing only on Cloudflare. Both predate emdash-cms#426, which added @emdash-cms/sandbox-workerd: sandboxed plugins on Node.js run in a workerd child process.
|
There was a problem hiding this comment.
This is the right documentation update in principle — the root README should list the Node.js workerd sandbox alongside the Cloudflare one, rather than leaving "In-process (safe mode)" as the only non-Cloudflare runtime. However, the new wording overstates the case: on Node.js in development, @emdash-cms/sandbox-workerd deliberately selects MiniflareDevRunner, which uses miniflare's in-process service-bindings pattern and explicitly avoids a workerd child process. The unqualified claim that Node.js plugins run "in a workerd child process" is therefore false for astro dev. I verified this against packages/workerd/src/sandbox/runner.ts (createSandboxRunner) and packages/workerd/src/sandbox/dev-runner.ts. The two line comments below propose a concise qualification so the summary and the portable-platforms table stay accurate without getting into implementation minutiae.
There was a problem hiding this comment.
The goal is right: the root README should list the Node.js workerd sandbox alongside the Cloudflare one, since @emdash-cms/sandbox-workerd has replaced the old “In-process (safe mode)” default outside Cloudflare.
In the re-review, I focused on the disputed claim that under astro dev plugins don’t run in a workerd child process. The canonical docs in this repo (docs/src/content/docs/deployment/plugin-sandbox.mdx) explicitly say that in development EmDash hands the plugins to Miniflare, which manages its own workerd process. packages/workerd/src/sandbox/dev-runner.ts also describes itself as having “No child process management” — meaning the runner doesn’t manage the process, not that no workerd process exists. So the unqualified wording “workerd child process” is accurate for both production and astro dev.
With that resolved, the README change is technically accurate, minimal, and consistent with the existing docs. No other files are modified; no published package changed, so a changeset is correctly omitted. I have no remaining findings.
What does this PR do?
Updates the README for the Node.js plugin sandbox from #426. The platform table still gave "In-process (safe mode)" as the plugin runtime outside Cloudflare, a row written when sandboxing was Cloudflare-only, and the Plugins summary named only the Cloudflare sandbox. On Node.js,
@emdash-cms/sandbox-workerdruns sandboxed plugins in aworkerdchild process, so the table row and the summary now name it. Underastro dev, the runner hands the plugins to Miniflare, which starts its ownworkerdprocess, so the wording holds in development too. The Cloudflare column is unchanged.Follow-up to #425.
Type of change
Checklist
pnpm typecheckpasses (n/a: README only)pnpm lintpasses (n/a: README only)pnpm testpasses (or targeted tests for my change) (n/a: README only)pnpm formathas been runmessages.pochanges except in translation PRs — a workflow extracts catalogs on merge tomain. (n/a: no admin UI change)AI-generated code disclosure
Screenshots / test output
Not applicable.