chore(deps): update dependency wrangler to v4 #201
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
^3.91.0→^4.0.0Release Notes
cloudflare/workers-sdk (wrangler)
v4.64.0Compare Source
Minor Changes
#12433
2acb277Thanks @martinezjandrew! - Updated registries delete subcommand to handle new API response that now returns a secrets store secret reference after deletion. Wrangler will now prompt the user if they want to delete the associated secret. If so, added new logic to retrieve a secret by its name. The subcommand will then delete the secret.#12307
e02b5f5Thanks @dario-piotrowicz! - Improve autoconfig telemetry with granular event trackingAdds detailed telemetry events to track the autoconfig workflow, including process start/end, detection, and configuration phases. Each event includes a unique session ID (
appId), CI detection, framework information, and success/error status to help diagnose issues and understand usage patterns.#12474
8ba1d11Thanks @petebacondarwin! - Addwrangler pages deployment deletecommand to delete Pages deployments via CLIYou can now delete a Pages deployment directly from the command line:
Use the
--force(or-f) flag to skip the confirmation prompt, which is useful for CI/CD automation.#12307
e02b5f5Thanks @dario-piotrowicz! - Include all common telemetry properties in ad-hoc telemetry eventsPreviously, only command-based telemetry events (e.g., "wrangler command started/completed") included the full set of common properties. Ad-hoc events sent via
sendAdhocEventwere missing important context like OS information, CI detection, and session tracking.Now, all telemetry events include the complete set of common properties:
amplitude_session_idandamplitude_event_idfor session trackingwranglerVersion(and major/minor/patch variants)osPlatform,osVersion,nodeVersionpackageManagerconfigFileTypeisCI,isPagesCI,isWorkersCIisInteractiveisFirstUsagehasAssetsagent#12479
fd902aaThanks @dario-piotrowicz! - Add framework selection prompt during autoconfigWhen running autoconfig in interactive mode, users are now prompted to confirm or change the detected framework. This allows correcting misdetected frameworks or selecting a framework when none was detected, defaulting to "Static" in that case.
#12465
961705cThanks @petebacondarwin! - Add--jsonflag towrangler pages project listcommandYou can now use the
--jsonflag to output the project list as clean JSON instead of a formatted table. This enables easier programmatic processing and scripting workflows.#12470
21ac7abThanks @petebacondarwin! - AddWRANGLER_COMMANDenvironment variable to custom build commandsWhen using a custom build command in
wrangler.toml, you can now detect whetherwrangler devorwrangler deploytriggered the build by reading theWRANGLER_COMMANDenvironment variable.This variable will be set to
"dev","deploy","versions upload", or"types"depending on which command invoked the build. This allows you to customize your build process based on the deployment context.Example usage in a build script:
Patch Changes
#12468
5d56487Thanks @petebacondarwin! - Add debug logs for git branch detection inwrangler pages deploycommandWhen running
wrangler pages deploy, the command automatically detects git information (branch, commit hash, commit message, dirty state) from the local repository. Previously, when this detection failed, there was no way to troubleshoot the issue.Now, running with
WRANGLER_LOG=debugwill output detailed information about:Example usage:
#12447
c8dda16Thanks @dario-piotrowicz! - fix: Throw a descriptive error when autoconfig cannot detect an output directoryWhen running
wrangler setuporwrangler deploy --x-autoconfigon a project where the output directory cannot be detected, you will now see a clear error message explaining what's missing (e.g., "Could not detect a directory containing the static (html, css and js) files for the project") instead of a generic configuration error. This makes it easier to understand and resolve the issue.#12440
555b32aThanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12485
d636d6aThanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12502
bf8df0cThanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12280
988dea9Thanks @penalosa! - Fixwrangler initfailing with Yarn ClassicWhen using Yarn Classic (v1.x), running
wrangler initorwrangler init --from-dashwould fail because Yarn Classic doesn't properly handle version specifiers with special characters like^inyarn createcommands. Yarn would install the package correctly but then fail to find the binary because it would look for a path like.yarn/bin/create-cloudflare@^2.5.0instead of.yarn/bin/create-cloudflare.This fix removes the version specifier from the default C3 command entirely. Since C3 has had auto-update behavior for over two years, specifying a version is no longer necessary and removing it resolves the Yarn Classic compatibility issue.
#12486
1f1c3ceThanks @vicb! - Bump esbuild to 0.27.3This update includes several bug fixes from esbuild versions 0.27.1 through 0.27.3. See the esbuild changelog for details.
#12472
62635a0Thanks @petebacondarwin! - Improve D1 database limit error message to match Cloudflare dashboardWhen attempting to create a D1 database after reaching your account's limit, the CLI now shows a more helpful error message with actionable guidance instead of the raw API error.
The new message includes:
#12411
355c6daThanks @jbwcloudflare! - Fixwrangler pages deployto respect increased file count limits#12449
bfd17cdThanks @penalosa! - fix: Display unsafe metadata separately from bindingsUnsafe metadata are not bindings and should not be displayed in the bindings table. They are now printed as a separate JSON block.
Before:
After:
#12463
3388c84Thanks @petebacondarwin! - Add User-Agent header to remote dev inspector WebSocket connectionsWhen running
wrangler dev --remote, the inspector WebSocket connection now includes aUser-Agentheader (wrangler/<version>). This resolves issues where WAF rules blocking empty User-Agent headers prevented remote dev mode from working with custom domains.#12421
937425cThanks @ryanking13! - Fix Python Workers deployment failing on Windows due to path separator handlingPreviously, deploying Python Workers on Windows would fail because the backslash path separator (
\) was not properly handled, causing the entire full path to be treated as a single filename. The deployment process now correctly normalizes paths to use forward slashes on all platforms.Updated dependencies [
2d90127,555b32a,d636d6a,bf8df0c,312b5eb,ce9dc01]:v4.63.0Compare Source
Minor Changes
#12386
447daa3Thanks @NuroDev! - Added new "open local explorer" hotkey for experimental/WIP local resource explorerWhen running
wrangler devwith the experimental local explorer feature enabled, you can now press theehotkey to open the local resource explorer UI in your browser.Patch Changes
#11350
ee9b81fThanks @dario-piotrowicz! - fix: improve error message when the entrypoint is incorrectError messages for incorrect entrypoint configuration have been improved to provide clearer and more actionable feedback. The updated messages help users understand what went wrong and how to fix their configuration.
#12402
63f1adbThanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12418
ba13de9Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12216
fe3af35Thanks @ichernetsky-cf! - Deprecate 'wrangler cloudchamber apply' in favor of 'wrangler deploy'#12368
bd4bb98Thanks @KianNH! - Preserve Containers configuration when usingversionscommandsPreviously, commands like
wrangler versions uploadwould inadvertently disable Containers on associated Durable Object namespaces because thecontainersproperty was being omitted from the API request body.#12396
dab4bc9Thanks @petebacondarwin! - fix: redact email addresses and account names in non-interactive modeTo prevent sensitive information from being exposed in public CI logs, email addresses and account names are now redacted when running in non-interactive mode (e.g., CI environments). Account IDs remain visible to aid debugging.
#12378
18c0784Thanks @X6TXY! - Truncate Pages commit messages at UTF-8 boundaries to avoid invalid UTF-8Updated dependencies [
63f1adb,ba13de9,83adb2c]:v4.62.0Compare Source
Minor Changes
#12064
964a39dThanks @G4brym! - Add AI Search OAuth scopes to loginAdds
ai-search:writeandai-search:runOAuth scopes to the default login scopes, enabling wrangler to authenticate with AI Search APIs.#11867
253a85dThanks @rahulsuresh-git! - Addwrangler r2 bucket local-uploadscommand to manage local uploads for R2 bucketsWhen enabled, object data is written to the nearest region first, then asynchronously replicated to the bucket's primary region.
Docs: https://developers.cloudflare.com/r2/buckets/local-uploads
#11803
1bd1488Thanks @dario-piotrowicz! - Add a newsubrequestslimit to thelimitsfield of the Wrangler configuration fileBefore only the
cpu_mslimit was supported in thelimitsfield of the Wrangler configuration file, now asubrequestslimit can be specified as well which enables the user to limit the number of fetch requests that a Worker's invocation can make.Example:
{ "$schema": "./node_modules/wrangler/config-schema.json", "limits": { "cpu_ms": 1000, "subrequests": 150 // newly added field } }#12185
f7aa8c7Thanks @penalosa! - Addtimestampfield to the version metadata binding in local development. The version metadata binding now includesid,tag, andtimestampfields, making it easier to test version-aware logic locally.Patch Changes
#12190
ce736b9Thanks @dario-piotrowicz! - Update autoconfig logic to handle Next.js projects by using the new@opennextjs/cloudflare migratecommand#12065
47944d1Thanks @langningchen! - Improve error message whend1 export --outputpoints to a directory#12292
4c4d5a5Thanks @dario-piotrowicz! - AddversionCommandto theautoconfig_summaryfield in the autoconfig output entryAdd the version upload command to the output being printed by
wrangler deploytoWRANGLER_OUTPUT_FILE_DIRECTORY/WRANGLER_OUTPUT_FILE_PATH. This complements the existingbuildCommandanddeployCommandfields and allows CI systems to know how to upload new versions of Workers.For example, for a standard npm project this would be:
npx wrangler versions uploadWhile for a Next.js project it would be:
npx @​opennextjs/cloudflare upload#12050
b05b919Thanks @NuroDev! - Fixed Wrangler's error handling for both invalid commands with and without the--helpflag, ensuring consistent and clear error messages.Additionally, it also ensures that if you provide an invalid argument to a valid command, Wrangler will now correctly display that specific commands help menu.
#12289
0aaf080Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12295
b981db5Thanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12355
a113c0dThanks @dependabot! - Update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#11971
fdd7a9fThanks @dario-piotrowicz! - Add framework id, build command, and deploy command to theautoconfig_summaryfield in the deploy output entryAdd the framework id alongside the commands to build and deploy the project to the output being printed by
wrangler deploytoWRANGLER_OUTPUT_FILE_DIRECTORYorWRANGLER_OUTPUT_FILE_PATH.For example for an npm Astro project these would be:
astronpm run buildnpx wrangler deployWhile for a Next.js project they would instead be:
nextnpx @​opennextjs/cloudflare buildnpx @​opennextjs/cloudflare deploy#12211
a5fca2cThanks @elithrar! - Remove the 'pubsub' sub-command and related functionalityThe Pub/Sub product was never made publicly available and has been discontinued. This removes the
wrangler pubsubcommand and all associated functionality.Updated dependencies [
0c9625a,0aaf080,b981db5,a113c0d,f7aa8c7]:v4.61.1Compare Source
Patch Changes
#12189
eb8a415Thanks @NuroDev! - Fixed Durable Object missing migrations warning message.If a Workers project includes some
durable_objectsin it but nomigrationswe show a warning to the user to addmigrationsto their config. However, this warning recommendednew_classesfor their migrations, but we instead now recommend all users usenew_sqlite_classesinstead.#11804
3b06b18Thanks @emily-shen! - fix: allowd1 execute,d1 export, andd1 migrationsto work locally withoutdatabase_idin config.#12183
17961bbThanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12196
52fdfe7Thanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12199
6d8d9cdThanks @petebacondarwin! - Preventwrangler logoutfrom failing when the Wrangler configuration file is invalidPreviously, if your
wrangler.tomlorwrangler.jsonfile contained syntax errors or invalid values, thewrangler logoutcommand would fail. Now, configuration parsing errors are caught and logged at debug level, allowing you to log out regardless of the state of your configuration file.#12153
cb72c11Thanks @petebacondarwin! - Sanitize commands and arguments in telemetry to prevent accidentally capturing sensitive information.Changes:
command/argstosanitizedCommand/sanitizedArgsto distinguish from historical fields that may have contained sensitive data in older versionsCOMMAND_ARG_ALLOW_LISTUpdated dependencies [
8a210af,17961bb,52fdfe7,5f060c9]:v4.61.0Compare Source
Minor Changes
#12008
e414f05Thanks @penalosa! - Add support for customising the inspector IP addressAdds a new
--inspector-ipCLI flag anddev.inspector_ipconfiguration option to allow customising the IP address that the inspector server listens on. Previously, the inspector was hardcoded to listen only on127.0.0.1.Example usage:
# CLI flag wrangler dev --inspector-ip 0.0.0.0#12034
05714f8Thanks @emily-shen! - Add a no-op local explorer worker, which is gated by the experimental flagX_LOCAL_EXPLORER.Patch Changes
#12134
a0a9ef6Thanks @NuroDev! - Fixed Fish shell tab completions.The
wranglertab completions are powered by@bomb.sh/tabwhich has been upgraded to version0.0.12which includes a fix for the Fish shell which was previously not working at all.#12006
ad4666cThanks @penalosa! - Remove--use-remoteoption fromwrangler hyperdrive createcommandHyperdrive does not support remote bindings during local development - it requires a
localConnectionStringto connect to a local database. This change removes the confusing "remote resource" prompt that was shown when creating a Hyperdrive config.Fixes #11674
#11853
014e7aaThanks @43081j! - Use built-in stripVTControlCharacters utility rather than thestrip-ansipackage.#12040
77e82d2Thanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12061
f08ef21Thanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12088
0641e6cThanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12044
eacedbaThanks @edmundhung! - Fixwrangler secret listto error when the Worker is not foundPreviously, running
wrangler secret listagainst a non-existent Worker would silently return an empty array, making it difficult to diagnose issues like being logged into the wrong account. It now returns an error with suggestions for common causes.#12150
e8b2ef5Thanks @dario-piotrowicz! - Emit autoconfig summary as a separate output entryMove the autoconfig summary from the
deployoutput entry to a dedicatedautoconfigoutput entry type. This entry is now emitted by bothwrangler deployandwrangler setupcommands when autoconfig runs, making it easier to track autoconfig results independently of deployments.Updated dependencies [
014e7aa,e414f05,77e82d2,f08ef21,0641e6c,05714f8,bbd8a5e]:v4.60.0Compare Source
Minor Changes
#11113
bba0968Thanks @AmirSa12! - Addwrangler completecommand for shell completion scripts (bash, zsh, powershell)Usage:
@bomb.sh/tablibrary for cross-shell compatibilityexperimental_getWranglerCommands()API#11893
f9e8a45Thanks @NuroDev! -wrangler typesnow generates per-environment TypeScript interfaces when named environments exist in your configuration.When your configuration has named environments (an
envobject),wrangler typesnow generates both:StagingEnv,ProductionEnv) containing only the bindings explicitly declared in each environment, plus inherited secretsEnvinterface with all bindings from all environments (top-level + named environments), where:KVNamespace | R2Bucket)However, if your config does not contain any environments, or you manually specify an environment via
--env,wrangler typeswill continue to generate a single interface as before.Example:
Given the following
wrangler.jsonc:{ "name": "my-worker", "kv_namespaces": [ { "binding": "SHARED_KV", "id": "abc123", }, ], "env": { "staging": { "kv_namespaces": [ { "binding": "SHARED_KV", "id": "staging-kv" }, { "binding": "STAGING_CACHE", "id": "staging-cache" }, ], }, }, }Running
wrangler typeswill generate:Patch Changes
#12030
614bbd7Thanks @jbwcloudflare! - Fixwrangler pages project validateto respect file count limits fromCF_PAGES_UPLOAD_JWT#11993
788bf78Thanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#12039
1375577Thanks @dimitropoulos! - Fixed the flag casing for the time period flag for thed1 insightscommand.#12026
c3407adThanks @dario-piotrowicz! - Fixwrangler setupnot automatically selectingworkersas the target for new SvelteKit appsThe Sveltekit
adapter:cloudflareadapter now accepts two different targetsworkersorpages. Since the wrangler auto configuration only targets workers, wrangler should instruct the adapter to use theworkersvariant. (The auto configuration process would in any case not work if the user were to targetpages.)Updated dependencies [
788bf78,ae108f0]:v4.59.3Compare Source
Patch Changes
#9396
75386b1Thanks @gnekich! - Fixwrangler loginwith customcallback-host/callback-portThe Cloudflare OAuth API always requires the
redirect_urito belocalhost:8976. However, sometimes the Wrangler OAuth server needed to listen on a different host/port, for example when running from inside a container. We were previously incorrectly setting theredirect_urito the configured callback host/port, but it needs to be up to the user to maplocalhost:8976to the Wrangler OAuth server in the container.Example:
You might run Wrangler inside a docker container like this:
docker run -p 8989:8976 <image>, which forwards port 8976 on your host to 8989 inside the container.Then inside the container, run
wrangler login --callback-host=0.0.0.0 --callback-port=8989The OAuth link still has a
redirect_uriset tolocalhost:8976. For examplehttps://dash.cloudflare.com/oauth2/auth?...&redirect_uri=http%3A%2F%2Flocalhost%3A8976%2Foauth%2Fcallback&...However the redirect to
localhost:8976is then forwarded to the Wrangler OAuth server inside your container, allowing the login to complete.#11925
8e4a0e5Thanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#11942
133bf95Thanks @penalosa! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#11922
93d8d78Thanks @dario-piotrowicz! - Improve telemetry errors being sent to Sentry bywrangler initwhen it delegates to C3 by ensuring that they contain the output of the C3 execution.#11940
69ff962Thanks @penalosa! - Show helpful messages for file not found errors (ENOENT)When users encounter file not found errors, Wrangler now displays a helpful message with the missing file path and common causes, instead of reporting to Sentry.
#11904
22727c2Thanks @danielrs! - Fix false positive infinite loop detection for exact path redirectsFixed an issue where the redirect validation incorrectly flagged exact path redirects like
/ /index.html 200as infinite loops. This was particularly problematic whenhtml_handlingis set to "none", where such redirects are valid.The fix makes the validation more specific to only block wildcard patterns (like
/* /index.html) that would actually cause infinite loops, while allowing exact path matches that are valid in certain configurations.Fixes: #11824
#11946
fa39a73Thanks @MattieTK! - FixconfigFileNamereturning wrong filename for.jsoncconfig filesPreviously, users with a
wrangler.jsoncconfig file would see error messages and hints referring towrangler.jsoninstead ofwrangler.jsonc. This was because theconfigFormatfunction collapsed both.jsonand.jsoncfiles into a single"jsonc"value, losing the distinction between them.Now
configFormatreturns"json"for.jsonfiles and"jsonc"for.jsoncfiles, allowingconfigFileNameto return the correct filename for each format.#11968
4ac7c82Thanks @MattieTK! - fix: include version components in command event metricsAdds
wranglerMajorVersion,wranglerMinorVersion, andwranglerPatchVersionto command events (wrangler command started,wrangler command completed,wrangler command errored). These properties were previously only included in adhoc events.#11940
69ff962Thanks @penalosa! - Improve error message when creating duplicate KV namespaceWhen attempting to create a KV namespace with a title that already exists, Wrangler now provides a clear, user-friendly error message instead of the generic API error. The new message explains that the namespace already exists and suggests running
wrangler kv namespace listto see existing namespaces with their IDs, or choosing a different namespace name.#11962
029531aThanks @dario-piotrowicz! - Cache chosen account in memory to avoid repeated promptsWhen users have multiple accounts and no
node_modulesdirectory exists for file caching, Wrangler (run vianpxand equivalent commands) would prompt for account selection multiple times during a single command. Now the selected account is also stored in process memory, preventing duplicate prompts and potential issues from inconsistent account choices.#11964
d58fbd1Thanks @dario-piotrowicz! - Makenamethe positional argument forwrangler deleteinstead ofscriptThe
scriptargument was meaningless for the delete command since it deletes by worker name, not by entry point path. Thenameargument is now accepted as a positional argument, allowing users to runwrangler delete my-workerinstead ofwrangler delete --name my-worker. Thescriptargument is now hidden but still accepted for backwards compatibility.#11967
202c59eThanks @emily-shen! - chore: update undiciThe following dependency versions have been updated:
#11940
69ff962Thanks @penalosa! - Improve error handling for Vite config transformationsReplace assertions with proper error handling when transforming Vite configs. When Wrangler encounters a Vite config that uses a function or lacks a plugins array, it now provides clear, actionable error messages instead of crashing with assertion failures. The check function gracefully skips incompatible configs with debug logging.
Updated dependencies [
8e4a0e5,133bf95,202c59e,133bf95,25e2c60]:v4.59.2Compare Source
Patch Changes
#11908
e78186dThanks @dependabot! - chore: update dependencies of "miniflare", "wrangler"The following dependency versions have been updated:
#11880
fe4faa3Thanks @penalosa! - Show helpful messages for errors outside of Wrangler's control. This prevents unnecessary Sentry reports.Errors now handled with user-friendly messages:
UND_ERR_CONNECT_TIMEOUT) - typically due to slow networks or connectivity issuesEPERM,EACCES) - caused by insufficient permissions, locked files, or antivirus softwareENOTFOUND) - caused by network connectivity issues or DNS configuration problems#11882
695b043Thanks @GregBrimble! - Improve the error message forwrangler secret putwhen using Worker versions or gradual deployments.wrangler versions secret putshould be used instead, or ensure to deploy the latest version before usingwrangler secret put.wrangler secret putalone will add the new secret to the latest version (possibly undeployed) and immediately deploy that which is usually not intended.Updated dependencies [
e78186d,fec8f5b,d39777f,4714ca1, [c17e971](https://redirect.github.com/cloudflare/workers-sdk/commit/c17e971af01a9bcead0aca409666e294Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.