Skip to content

@cloudflare/build-output-utils v1 RC - #16917

Merged
petebacondarwin merged 1 commit into
james/config-rc-apifrom
james/build-output-v1
Nov 16, 2026
Merged

petebacondarwin merged 1 commit into
james/config-rc-apifrom
james/build-output-v1

Conversation

@jamesopstad

Copy link
Copy Markdown
Contributor

Release the first 1.0.0 release candidate, which reads and writes Build Output v1

Build Output now lives in .cloudflare/output/v1/. Only the .cloudflare/output/v<N>/ naming convention is permanent: a future breaking change to the format would use a new version directory. readBuildOutput() lists the version directories first and throws a BuildOutputError unless it finds exactly one v1 directory. This means output written by an older or newer tool, or a stale v0 tree left next to a fresh one, fails with a clear error instead of being misread or deployed.

BuildOutputError now has a code (not-found, newer-version, older-version, multiple-versions, unknown-fields or invalid) plus foundVersions, supportedVersions, producer and unknownFields. Consumers can use these to show their own advice instead of parsing the message. When a config contains fields the reader doesn't support, the error lists each field and names the tool that wrote the output.

The root config.json now nests account settings under settings, which is left out when none are set, and can record the tool that wrote the output in an optional producer field. writeRootConfig() takes an options object, matching the other write* functions:

// Before
await writeRootConfig(root, settings, buildContext);

// After
await writeRootConfig({
	root,
	settings,
	buildContext,
	producer: { name: "my-framework-adapter", version: "1.2.3" },
});

  • 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: docs to follow

A picture of a cute animal (not mandatory, but encouraged)

@changeset-bot

changeset-bot Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 1c68442

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

This PR includes changesets to release 10 packages
Name Type
@cloudflare/build-output-utils Major
@cloudflare/vite-plugin Minor
wrangler Minor
@cloudflare/deploy-helpers Patch
create-cloudflare Patch
@cloudflare/config Minor
@cloudflare/containers-shared Patch
@cloudflare/vitest-plugin Patch
@cloudflare/remote-bindings Patch
@cloudflare/autoconfig 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

@github-project-automation github-project-automation Bot moved this to Untriaged in workers-sdk Nov 13, 2026
@jamesopstad
jamesopstad changed the base branch from main to james/config-rc-api November 13, 2026 18:52
@jamesopstad
jamesopstad added this pull request to stack #16918 November 13, 2026 18:52
@ask-bonk

ask-bonk Bot commented Nov 13, 2026

Copy link
Copy Markdown
Contributor

LGTM

github run

@jamesopstad
jamesopstad marked this pull request as ready for review November 13, 2026 18:55
@pkg-pr-new

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

Copy link
Copy Markdown
@cloudflare/autoconfig

npm i https://pkg.pr.new/@cloudflare/autoconfig@16917

@cloudflare/build-output-utils

npm i https://pkg.pr.new/@cloudflare/build-output-utils@16917

@cloudflare/codemods

npm i https://pkg.pr.new/@cloudflare/codemods@16917

@cloudflare/config

npm i https://pkg.pr.new/@cloudflare/config@16917

@cloudflare/containers-shared

npm i https://pkg.pr.new/@cloudflare/containers-shared@16917

create-cloudflare

npm i https://pkg.pr.new/create-cloudflare@16917

@cloudflare/deploy-helpers

npm i https://pkg.pr.new/@cloudflare/deploy-helpers@16917

@cloudflare/kv-asset-handler

npm i https://pkg.pr.new/@cloudflare/kv-asset-handler@16917

miniflare

npm i https://pkg.pr.new/miniflare@16917

@cloudflare/pages-functions

npm i https://pkg.pr.new/@cloudflare/pages-functions@16917

@cloudflare/pages-shared

npm i https://pkg.pr.new/@cloudflare/pages-shared@16917

@cloudflare/runtime-types

npm i https://pkg.pr.new/@cloudflare/runtime-types@16917

@cloudflare/unenv-preset

npm i https://pkg.pr.new/@cloudflare/unenv-preset@16917

@cloudflare/vite-plugin

npm i https://pkg.pr.new/@cloudflare/vite-plugin@16917

@cloudflare/vitest-plugin

npm i https://pkg.pr.new/@cloudflare/vitest-plugin@16917

@cloudflare/workers-auth

npm i https://pkg.pr.new/@cloudflare/workers-auth@16917

@cloudflare/workers-editor-shared

npm i https://pkg.pr.new/@cloudflare/workers-editor-shared@16917

@cloudflare/workers-utils

npm i https://pkg.pr.new/@cloudflare/workers-utils@16917

wrangler

npm i https://pkg.pr.new/wrangler@16917

commit: a89025f

@workers-devprod
workers-devprod requested review from a team and edmundhung and removed request for a team November 13, 2026 18:55
@workers-devprod

workers-devprod commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Codeowners approval required for this PR:

  • ✅ @cloudflare/wrangler
Show detailed file reviewers

devin-ai-integration[bot]

This comment was marked as resolved.

clanky-the-clanker[bot]

This comment was marked as resolved.

@jamesopstad
jamesopstad force-pushed the james/build-output-v1 branch from fcd750a to b8ae10f Compare November 13, 2026 19:10

@clanky-the-clanker clanky-the-clanker 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.

Superseded by the review of 1c68442a.

This review, of b8ae10f9

💬 Approved with comments — The fixes since the last review are correct and tested. The only note left is a SUGGESTION about the duplicated version-directory regex.

Findings: 1 suggestion

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


📋 Code Quality: 💬 1 suggestion

The symlink mismatch in the guard is fixed. The version-directory pattern is still defined in two places.

Recommendation: 💬 Optional Nits

  • [SUGGESTION] VERSION_DIRECTORY_PATTERN is defined in both Wrangler and build-output-utils/src/read.ts (packages/wrangler/src/deployment-bundle/cf-build-output-guard.ts:58)
View full review
  • Fixed: symlinked v<N> entry. findCloudflareBuildOutput now accepts entry.isDirectory() || entry.isSymbolicLink(), which matches the reader, and a test covers it.
  • create-cloudflare/src/cf/deploy.ts: checks v1 before v0. The error message still names the v1 path when neither exists, and the tests cover all three cases.
  • Still open: VERSION_DIRECTORY_PATTERN is defined in both Wrangler and build-output-utils.

✅ All other checks passed

🚀 Release: ✅ LGTM

Risk: Low. The changesets cover the affected packages.


🔒 Security: ✅ LGTM

The C3 config paths are fixed constants joined to the project path. Counting a symlinked v<N> entry makes the guard stricter, and the reader still rejects symlinks inside the selected version directory.


📖 AGENTS.md: ✅ LGTM

No issues found.


⚡ Performance: ✅ LGTM

No issues found.


📝 Documentation: ✅ LGTM

No issues found.


Reviewed commit: b8ae10f9

@clanky-the-clanker clanky-the-clanker 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.

Superseded by the review of a89025f6.

This review, of 1c68442a

💬 Approved with comments — The fixes since the last review are correct and tested. The only note left is a SUGGESTION about the duplicated version-directory regex.

Findings: 1 suggestion

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


📋 Code Quality: 💬 1 suggestion

The symlink mismatch in the guard is fixed. The version-directory pattern is still defined in two places.

Recommendation: 💬 Optional Nits

  • [SUGGESTION] VERSION_DIRECTORY_PATTERN is defined in both Wrangler and build-output-utils/src/read.ts (packages/wrangler/src/deployment-bundle/cf-build-output-guard.ts:58)
View full review
  • Fixed: symlinked v<N> entry. findCloudflareBuildOutput now accepts entry.isDirectory() || entry.isSymbolicLink(), which matches the reader, and a test covers it.
  • create-cloudflare/src/cf/deploy.ts: checks v1 before v0. The error message still names the v1 path when neither exists, and the tests cover all three cases.
  • Still open: VERSION_DIRECTORY_PATTERN is defined in both Wrangler and build-output-utils.

✅ All other checks passed

🚀 Release: ✅ LGTM

Risk: Low. The changesets cover the affected packages.


🔒 Security: ✅ LGTM

The C3 config paths are fixed constants joined to the project path. Counting a symlinked v<N> entry makes the guard stricter, and the reader still rejects symlinks inside the selected version directory.


📖 AGENTS.md: ✅ LGTM

No issues found.


⚡ Performance: ✅ LGTM

No issues found.


📝 Documentation: ✅ LGTM

No issues found.


Reviewed commit: 1c68442a — same changes as b8ae10f9, so this is that commit's review (no new review was run; line numbers are as of b8ae10f9)

@jamesopstad

Copy link
Copy Markdown
Contributor Author

#16922 needs to be merged for the tests in this PR to pass.

@petebacondarwin
petebacondarwin removed the request for review from edmundhung November 16, 2026 10:04

@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

@github-project-automation github-project-automation Bot moved this from Untriaged to Approved in workers-sdk Nov 16, 2026

@clanky-the-clanker clanky-the-clanker 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.

💬 Approved with comments — The fixes since the last review are correct and tested. The only note left is a SUGGESTION about the duplicated version-directory regex.

Findings: 1 suggestion

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


📋 Code Quality: 💬 1 suggestion

The symlink mismatch in the guard is fixed. The version-directory pattern is still defined in two places.

Recommendation: 💬 Optional Nits

  • [SUGGESTION] VERSION_DIRECTORY_PATTERN is defined in both Wrangler and build-output-utils/src/read.ts (packages/wrangler/src/deployment-bundle/cf-build-output-guard.ts:58)
View full review
  • Fixed: symlinked v<N> entry. findCloudflareBuildOutput now accepts entry.isDirectory() || entry.isSymbolicLink(), which matches the reader, and a test covers it.
  • create-cloudflare/src/cf/deploy.ts: checks v1 before v0. The error message still names the v1 path when neither exists, and the tests cover all three cases.
  • Still open: VERSION_DIRECTORY_PATTERN is defined in both Wrangler and build-output-utils.

✅ All other checks passed

🚀 Release: ✅ LGTM

Risk: Low. The changesets cover the affected packages.


🔒 Security: ✅ LGTM

The C3 config paths are fixed constants joined to the project path. Counting a symlinked v<N> entry makes the guard stricter, and the reader still rejects symlinks inside the selected version directory.


📖 AGENTS.md: ✅ LGTM

No issues found.


⚡ Performance: ✅ LGTM

No issues found.


📝 Documentation: ✅ LGTM

No issues found.


Reviewed commit: a89025f6 — same changes as b8ae10f9, so this is that commit's review (no new review was run; line numbers are as of b8ae10f9)

@petebacondarwin
petebacondarwin merged commit d36b39d into main Nov 16, 2026
84 checks passed
@petebacondarwin
petebacondarwin deleted the james/build-output-v1 branch November 16, 2026 11:05
@github-project-automation github-project-automation Bot moved this from Approved to Done in workers-sdk Nov 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants