Skip to content

feat(wrangler): automate names for agent-driven deploys - #14907

Merged
NuroDev merged 5 commits into
mainfrom
fix/agent-default-worker-name
Jul 29, 2026
Merged

feat(wrangler): automate names for agent-driven deploys#14907
NuroDev merged 5 commits into
mainfrom
fix/agent-default-worker-name

Conversation

@NuroDev

@NuroDev NuroDev commented Jul 29, 2026

Copy link
Copy Markdown
Member

Prevent agent-driven deploys from pausing for Worker and workers.dev subdomain naming.

When Wrangler detects a pure agent environment, it now derives the Worker name from the project, skips autoconfig naming confirmations, and automatically registers a project-derived workers.dev account subdomain on the first deploy. Human-driven deploys retain the existing interactive flow.

Agent-generated Worker names also use the existing collision guard to avoid overwriting an unrelated Worker. Deploy output explains how the user can change both names.


  • 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: This only changes agent-specific prompt behavior, and Wrangler's deploy output explains how to change the generated names.

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

@changeset-bot

changeset-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 06bf48f

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

This PR includes changesets to release 3 packages
Name Type
wrangler Minor
@cloudflare/vite-plugin Patch
@cloudflare/vitest-pool-workers 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 Jul 29, 2026
@NuroDev NuroDev self-assigned this Jul 29, 2026
@github-actions

Copy link
Copy Markdown
Contributor

✅ All changesets look good

ask-bonk[bot]

This comment was marked as resolved.

@ask-bonk

ask-bonk Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Review posted successfully to PR #14907.

Summary: I reviewed the PR and found one actionable issue — the automatic workers.dev subdomain registration (props.autoRegisterWorkersDevSubdomain) is gated on detectedAgent.isAgent alone rather than shouldUseProjectName. When an agent deploy provides an explicit Worker name (via --name or config), this causes (1) a subdomain/worker-name mismatch and (2) a silent, effectively irreversible account-wide subdomain registration the user didn't opt into. Posted a suggestion to gate on shouldUseProjectName instead.

github run

@pkg-pr-new

pkg-pr-new Bot commented Jul 29, 2026

Copy link
Copy Markdown
@cloudflare/autoconfig

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

@cloudflare/config

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

create-cloudflare

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

@cloudflare/deploy-helpers

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

@cloudflare/kv-asset-handler

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

miniflare

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

@cloudflare/pages-shared

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

@cloudflare/unenv-preset

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

@cloudflare/vite-plugin

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

@cloudflare/vitest-pool-workers

npm i https://pkg.pr.new/@cloudflare/vitest-pool-workers@14907

@cloudflare/workers-auth

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

@cloudflare/workers-editor-shared

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

@cloudflare/workers-utils

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

wrangler

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

commit: 06bf48f

@NuroDev
NuroDev marked this pull request as ready for review July 29, 2026 14:36
@NuroDev
NuroDev requested a review from workers-devprod as a code owner July 29, 2026 14:36
@workers-devprod
workers-devprod requested review from a team and petebacondarwin and removed request for a team July 29, 2026 14:37
@workers-devprod

workers-devprod commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Codeowners approval required for this PR:

  • ✅ @cloudflare/wrangler
Show detailed file reviewers

@devin-ai-integration devin-ai-integration 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.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 2 additional findings.

Open in Devin Review

Comment thread packages/deploy-helpers/src/triggers/subdomain.ts Outdated
devin-ai-integration[bot]

This comment was marked as resolved.

@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 Jul 29, 2026
@NuroDev
NuroDev enabled auto-merge (squash) July 29, 2026 15:07
Comment thread packages/deploy-helpers/src/triggers/subdomain.ts
Comment thread packages/wrangler/src/deploy/autoconfig.ts
@NuroDev
NuroDev merged commit beec0fb into main Jul 29, 2026
76 of 77 checks passed
@NuroDev
NuroDev deleted the fix/agent-default-worker-name branch July 29, 2026 15:38
@github-project-automation github-project-automation Bot moved this from Approved to Done in workers-sdk Jul 29, 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