Skip to content

Support the Cloudflare config 1.0 release candidate and Build Output v1 - #622

Merged
petebacondarwin merged 3 commits into
mainfrom
james/workers-sdk-v1-rc
Nov 16, 2026
Merged

petebacondarwin merged 3 commits into
mainfrom
james/workers-sdk-v1-rc

Conversation

@jamesopstad

@jamesopstad jamesopstad commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Support the Cloudflare config 1.0 release candidate and Build Output v1 using the published Workers SDK release.

cf now reads and writes Build Output under .cloudflare/output/v1/. The root config.json keeps account settings under settings and records the producer. Output in the older v0 format is rejected, so projects must be rebuilt before deployment. Container max_instances defaults to 20 when omitted, matching Wrangler.

Replace the Workers SDK preview packages with published npm versions, including @cloudflare/config@1.0.0-rc.0, @cloudflare/build-output-utils@1.0.0-rc.0, and @cloudflare/autoconfig@0.13.0. Require Wrangler 4.163.0 or newer and @cloudflare/vite-plugin 2.0.0-rc.0 or newer for compatible Build Output. Scaffold the Vite plugin RC in cf init and restore blockExoticSubdeps: true.

Keep the installed cf delegate fallback when autoconfig cannot resolve a native Vite command. This lets this migration land before the native Vite work in #540. The intended merge order is #622 → #540 → #634.

Validation:

  • pnpm check — all 7 tasks passed.
  • pnpm --filter cf test — 2,870 passed, 10 skipped.
  • Built CLI: Wrangler build and Vite+ RC build with --mode test produced Build Output v1 with the expected environment value.
  • Built CLI: cf init --no-install scaffolded @cloudflare/vite-plugin@^2.0.0-rc.0.

@pkg-pr-new

pkg-pr-new Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
npm i https://pkg.pr.new/cf@622

commit: d7edbf8

@github-actions

github-actions Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

cf --help startup

mean stddev min max
PR 225.1 ms 4.4 ms 219.9 ms 238.1 ms
base 223.9 ms 3.0 ms 220.4 ms 229.0 ms

Δ (PR vs base): ↑ +1.3 ms (+0.6%)

Measured with hyperfine on ubuntu-latest (3 warmup runs, 20 timed runs). CI numbers carry ±a few ms of runner jitter; treat small deltas as noise.

@ask-bonk

ask-bonk Bot commented Nov 13, 2026

Copy link
Copy Markdown
Contributor

LGTM

github run

@jamesopstad
jamesopstad force-pushed the james/workers-sdk-v1-rc branch from 1cdf431 to 5f41b4f Compare November 14, 2026 00:01
@jamesopstad
jamesopstad marked this pull request as ready for review November 14, 2026 00:01
@jamesopstad
jamesopstad requested a review from a team as a code owner November 14, 2026 00:01
@jamesopstad
jamesopstad requested a review from cjol November 14, 2026 00:01
@jamesopstad
jamesopstad marked this pull request as draft November 14, 2026 00:02

@clanky-the-clanker clanky-the-clanker Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Superseded by the review of d7edbf83.

This review, of 5f41b4f5

⚠️ Minor issues — 4 WARNINGs with real impact. Runtime dependencies point at pkg.pr.new URLs and would ship that way, and blockExoticSubdeps is off for the whole workspace. The Wrangler minimum still allows versions that write v0 output, which cf now rejects. The README states a Vite plugin minimum that cf no longer accepts. The description already lists most of these as steps to finish before merging.

Findings: 4 warnings · 1 info (3 are inline comments on the diff)

Not opened by the correctness review: 10 changed files it was meant to read
  • packages/cli/package.json
  • packages/cli/src/commands/deploy/containers.ts
  • packages/cli/src/commands/deploy/shared.ts
  • packages/cli/src/commands/deploy/static-assets.ts
  • packages/cli/src/commands/dev/known-impls.ts
  • packages/cli/src/commands/init/template.ts
  • packages/cli/src/commands/previews/deploy.ts
  • packages/cli/src/commands/workers/triggers/deploy.ts
  • packages/cli/src/lib/build-output.ts
  • packages/cli/src/lib/project-settings.ts

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

🔧 Fix with your agent

Paste the following into your coding agent to investigate and fix these issues.

Fix the following code review issues found in pull request #622.

Before making changes, review each issue and present a brief summary table:
- For each finding, state whether you agree, disagree, or need clarification
- If you disagree (e.g., the fix would require disproportionate changes
  for minimal ROI, or the finding is factually incorrect), explain why
- If you need to clarify something before deciding, ask those questions
- Then share your plan for which issues to tackle and in what order

## WARNING (4)

### [Release] Wrangler minimum is still 4.161.0. Projects built with Wrangler versions that write v0 output will be rejected by cf, and rebuilding with those versions does not help
- **File:** packages/cli/src/commands/dev/known-impls.ts:138

### [Security] blockExoticSubdeps is turned off for every transitive dependency, not only the workers-sdk preview packages
- **File:** pnpm-workspace.yaml:13

### [Code Quality] Published runtime dependencies point at commit-pinned pkg.pr.new tarballs and would ship to npm as URL dependencies
- **File:** packages/cli/package.json:72

### [Documentation] packages/cli/README.md:48 says Vite plugin 2.0.0-beta.v.13 or newer is supported, but cf now requires 2.0.0-rc.0 or newer
- **File:** packages/cli/README.md:48

## INFO (1)

### [Code Quality] The new `maxInstances ?? 20` default has no test for the unset case
- **File:** packages/cli/src/commands/deploy/containers.ts:224

📋 Code Quality: ⚠️ 1 warning · 1 info

Runtime dependencies use pkg.pr.new tarball URLs, and the new max_instances default has no test

Recommendation: 📝 Minor Comments

  • [WARNING] Published runtime dependencies point at commit-pinned pkg.pr.new tarballs and would ship to npm as URL dependencies (packages/cli/package.json:72)
  • [INFO] The new maxInstances ?? 20 default has no test for the unset case (packages/cli/src/commands/deploy/containers.ts:224)
View full review
  • Runtime dependencies on pkg.pr.new URLs (packages/cli/package.json:72-76): @cloudflare/build-output-utils, @cloudflare/config, @cloudflare/runtime-types and miniflare are in dependencies, so they ship with the published cf package. The Forge pkg.pr.new pin, by contrast, is a devDependency. The changeset marks this as a minor release. If it ships before these move back to npm versions, users installing cf get URL dependencies on preview builds, and those installs fail wherever URL or exotic dependencies are blocked. This is on the description's pre-merge list, but nothing in the repository enforces it.
  • max_instances default has no test (packages/cli/src/commands/deploy/containers.ts:224): the existing container test passes maxInstances: 20 explicitly. Removing the ?? DEFAULT_MAX_INSTANCES fallback would not fail any test.

🚀 Release: ⚠️ 1 warning

The Wrangler minimum still allows versions that write v0 Build Output

Recommendation: 📝 Minor Comments

  • [WARNING] Wrangler minimum is still 4.161.0. Projects built with Wrangler versions that write v0 output will be rejected by cf, and rebuilding with those versions does not help (packages/cli/src/commands/dev/known-impls.ts:138)
View full review

The changeset explains that v0 output is rejected and that projects must be rebuilt. However, packages/cli/src/commands/dev/known-impls.ts:137-138 still accepts wrangler >=4.161.0. cf build delegates to the selected implementation and then reads its Build Output. If a Wrangler version in that range still writes v0 output, rebuilding as the changeset instructs will not fix the failure. Raise the minimum to the first Wrangler release that writes v1 output, and update the README and tests to match. The description lists this as a pre-merge step.


🔒 Security: ⚠️ 1 warning

blockExoticSubdeps is disabled for the whole workspace

Recommendation: 📝 Minor Comments

  • [WARNING] blockExoticSubdeps is turned off for every transitive dependency, not only the workers-sdk preview packages (pnpm-workspace.yaml:13)
View full review
  • pnpm-workspace.yaml:13 sets blockExoticSubdeps to false. That allows any transitive dependency in the workspace to resolve from a git or tarball URL, not only the workers-sdk preview packages that need it. The comment marks this as temporary, and the description lists restoring it as a pre-merge step, but nothing enforces that.

📝 Documentation: ⚠️ 1 warning

The CLI README still states the old Vite plugin minimum

Recommendation: 📝 Minor Comments

  • [WARNING] packages/cli/README.md:48 says Vite plugin 2.0.0-beta.v.13 or newer is supported, but cf now requires 2.0.0-rc.0 or newer (packages/cli/README.md:48)
View full review
  • packages/cli/README.md:48 still says delegates support "Vite plugin v2 starting at 2.0.0-beta.v.13". The enforced range in packages/cli/src/commands/dev/known-impls.ts:121 is now >=2.0.0-rc.0, so users who follow the README with a beta release get an upgrade error. Update it to 2.0.0-rc.0. Update the Wrangler minimum on the same line when that version is raised.

✅ All other checks passed

📖 AGENTS.md: ✅ LGTM

No issues found.


⚡ Performance: ✅ LGTM

No performance concerns.


Reviewed commit: 5f41b4f5

Comment thread pnpm-workspace.yaml Resolved
Comment thread packages/cli/package.json Resolved
Comment thread pnpm-workspace.yaml Resolved
@ask-bonk

ask-bonk Bot commented Nov 14, 2026

Copy link
Copy Markdown
Contributor

🤖 I've done a thorough review of your PR.

Migrates cf to Build Output v1 and config 1.0 RC APIs.

  1. Posted one blocking inline suggestion.

github run

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

Configured Vite dev/build paths bypass the minimum plugin-version check, and the container fallback and explicit small-limit behavior lack regression coverage.

2 open issues
1 file not reviewed
  • pnpm-lock.yaml: Generated file
What changed in this PR

This PR adapts cf’s build and deployment workflows to the Cloudflare config 1.0 release candidate and Build Output v1.

Changes:

  • Migrate Build Output to .cloudflare/output/v1/, nest account settings, and record cf as the static-assets producer.
  • Default omitted Container limits to 20 and update Vite plugin requirements and scaffolding to the release candidate.
  • Update dependencies, tests, fixtures, and documentation; published dependency pins and dependency-policy restoration remain pre-merge steps.
File Description
pnpm-workspace.yaml Temporarily permit transitive URL dependencies.
pnpm-lock.yaml Lock workers-sdk preview builds.
packages/​wrangler-tests/​src/​__tests__/​versions/​versions.upload.test.ts Migrate upload fixtures to v1.
packages/​wrangler-tests/​src/​__tests__/​deploy/​core.test.ts Use v1 paths and nested account settings.
packages/​wrangler-tests/​package.json Update compatibility-test dependencies.
packages/​cli/​src/​lib/​project-settings.ts Adopt the renamed settings type.
packages/​cli/​src/​lib/​build-output.ts Read nested settings and updated config types.
packages/​cli/​src/​commands/​workers/​triggers/​deploy.ts Resolve accounts from nested settings.
packages/​cli/​src/​commands/​previews/​deploy.ts Use nested preview account settings.
packages/​cli/​src/​commands/​init/​template.ts Scaffold the Vite plugin release candidate.
packages/​cli/​src/​commands/​dev/​known-impls.ts Raise the Vite delegate minimum version.
packages/​cli/​src/​commands/​deploy/​static-assets.ts Write v1 output with producer metadata.
packages/​cli/​src/​commands/​deploy/​shared.ts Use nested deployment account settings.
packages/​cli/​src/​commands/​deploy/​containers.ts Adopt new types and default limits to 20.
packages/​cli/​src/​__tests__/​temporary-accounts.test.ts Migrate compliance fixtures to v1.
packages/​cli/​src/​__tests__/​lib/​deploy-input.test.ts Migrate module and asset fixtures to v1.
packages/​cli/​src/​__tests__/​lib/​context.test.ts Adopt the renamed settings type.
packages/​cli/​src/​__tests__/​lib/​build-output.test.ts Update reader and config-conversion fixtures.
packages/​cli/​src/​__tests__/​commands/​workers-check.test.ts Use v1 profiling fixtures.
packages/​cli/​src/​__tests__/​commands/​versions-upload.test.ts Migrate version-upload fixtures to v1.
packages/​cli/​src/​__tests__/​commands/​triggers-deploy.test.ts Update trigger fixtures and account settings.
packages/​cli/​src/​__tests__/​commands/​secrets-file.test.ts Use v1 deployment fixtures.
packages/​cli/​src/​__tests__/​commands/​previews-deploy.test.ts Nest preview account settings.
packages/​cli/​src/​__tests__/​commands/​previews-deploy-domains.test.ts Update preview paths and Worker schema.
packages/​cli/​src/​__tests__/​commands/​previews-deploy-containers.test.ts Migrate preview Container fixtures to v1.
packages/​cli/​src/​__tests__/​commands/​init.test.ts Assert the release-candidate scaffold dependency.
packages/​cli/​src/​__tests__/​commands/​dev/​index.test.ts Update version checks and installation hints.
packages/​cli/​src/​__tests__/​commands/​deploy/​subdomain.test.ts Migrate subdomain fixtures to v1.
packages/​cli/​src/​__tests__/​commands/​deploy/​routes.test.ts Migrate routing fixtures to v1.
packages/​cli/​src/​__tests__/​commands/​deploy/​index.test.ts Update deployment fixtures and nested settings.
packages/​cli/​src/​__tests__/​commands/​deploy/​errors.test.ts Update fixtures and missing-output expectations.
packages/​cli/​src/​__tests__/​commands/​deploy/​deploy-props.test.ts Migrate upload-metadata fixtures to v1.
packages/​cli/​src/​__tests__/​commands/​deploy/​containers.test.ts Adopt renamed Container config types.
packages/​cli/​src/​__tests__/​commands/​deploy/​assets.test.ts Assert v1 paths, settings, and producer metadata.
packages/​cli/​src/​__tests__/​commands/​build/​index.test.ts Update delegate versions and generated fixtures.
packages/​cli/​package.json Consume workers-sdk preview dependencies.
fixtures/​wrangler-bundler-project/​package.json Use the Wrangler preview build.
fixtures/​vite-plugin-project/​package.json Update Vite and Wrangler fixture dependencies.
fixtures/​vite-container-project/​package.json Update Container fixture dependencies.
docs/​architecture.md Document v1 output and release-candidate scaffolding.
.changeset/​workers-sdk-config-rc.md Record the user-facing migration and requirements.

Review effort: Balanced

@ask-bonk

ask-bonk Bot commented Nov 16, 2026

Copy link
Copy Markdown
Contributor

LGTM

github run

Comment thread packages/cli/src/lib/autoconfig.ts Resolved
@ask-bonk

ask-bonk Bot commented Nov 16, 2026

Copy link
Copy Markdown
Contributor

Review: 1 findings.

🤖 I've done a thorough review of your PR.

Migrates cf to Build Output v1 and config 1.0 RC dependencies.

Posted 1 inline suggestion.

github run

@petebacondarwin
petebacondarwin marked this pull request as ready for review November 16, 2026 13:14

@clanky-the-clanker clanky-the-clanker Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ Approved — The dependency pins, blockExoticSubdeps, Wrangler and Vite minimums, README version and missing max_instances test from the last review are all fixed, and nothing new needs flagging.

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


✅ All checks passed

🚀 Release: ✅ LGTM

The minor changeset covers Build Output v1, the new config layout, the container defaults and the new delegate minimums. Wrangler's minimum is now 4.163.0.


🔒 Security: ✅ LGTM

blockExoticSubdeps: true is restored, and the dependencies resolve from the npm registry.


📖 AGENTS.md: ✅ LGTM

No issues found.


📋 Code Quality: ✅ LGTM

The runtime dependencies use published npm versions. The containers test now omits maxInstances and checks the default of 20. The v1 settings reads and the new early return in autoconfig.ts are both correct.


⚡ Performance: ✅ LGTM

No performance concerns.


📝 Documentation: ✅ LGTM

The README now lists the Wrangler 4.163.0 and Vite plugin 2.0.0-rc.0 minimums.


Reviewed commit: d7edbf83

@petebacondarwin
petebacondarwin added this pull request to the merge queue Nov 16, 2026
Merged via the queue into main with commit 6df29e1 Nov 16, 2026
16 checks passed
@petebacondarwin
petebacondarwin deleted the james/workers-sdk-v1-rc branch November 16, 2026 13:26
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