chore(deps): update dependency wrangler to v3.28.1 #1051
Merged
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.26.0
->3.28.1
Release Notes
cloudflare/workers-sdk (wrangler)
v3.28.1
Compare Source
Patch Changes
#4962
d6585178
Thanks @mrbbot! - fix: ensurewrangler dev
can reload without crashing when importingnode:*
modulesThe previous Wrangler release introduced a regression that caused reloads to fail when importing
node:*
modules. This change fixes that, and ensures these modules can always be resolved.ffafe8ad
Thanks @nora-soderlund! - fix: D1 batch splitting to handle CASE as compound statement startsv3.28.0
Compare Source
Minor Changes
#4499
cf9c029b
Thanks @penalosa! - feat: Support runtime-agnostic polyfillsPreviously, Wrangler treated any imports of
node:*
modules as build-time errors (unless one of the two Node.js compatibility modes was enabled). This is sometimes overly aggressive, since those imports are often not hit at runtime (for instance, it was impossible to write a library that worked across Node.JS and Workers, using Node packages only when running in Node). Here's an example of a function that would cause Wrangler to fail to build:This function should work in both Workers and Node, since it gates Node-specific functionality behind a user agent check, and falls back to the built-in Workers crypto API. Instead, Wrangler detected the
node:crypto
import and failed with the following error:This change turns that Wrangler build failure into a warning, which users can choose to ignore if they know the import of
node:*
APIs is safe (because it will never trigger at runtime, for instance):However, in a lot of cases, it's possible to know at build time whether the import is safe. This change also injects
navigator.userAgent
intoesbuild
's bundle settings as a predefined constant, which means thatesbuild
can tree-shake away imports ofnode:*
APIs that are guaranteed not to be hit at runtime, supressing the warning entirely.#4926
a14bd1d9
Thanks @dario-piotrowicz! - feature: add acf
field to thegetBindingsProxy
resultAdd a new
cf
field to thegetBindingsProxy
result that people can use to mock the productioncf
(IncomingRequestCfProperties
) object.Example:
Patch Changes
#4931
321c7ed7
Thanks @dario-piotrowicz! - fix: make the entrypoint optional for thetypes
commandCurrently running
wrangler types
against awrangler.toml
file without a defined entrypoint (main
value)causes the command to error with the following message:
However developers could want to generate types without the entrypoint being defined (for example when using
getBindingsProxy
), so these changesmake the entrypoint optional for the
types
command, assuming modules syntax if none is specified.#4867
d637bd59
Thanks @RamIdeas! - fix: inflight requests to UserWorker which failed across reloads are now retriedPreviously, when running
wrangler dev
, requests inflight during a UserWorker reload (due to config or source file changes) would fail.Now, if those inflight requests are GET or HEAD requests, they will be reproxied against the new UserWorker. This adds to the guarantee that requests made during local development reach the latest worker.
4a735c46
Thanks @sdnts! - fix: Update API calls for Sippy's endpoints#4938
75bd08ae
Thanks @rozenmd! - fix: print wrangler banner at the start of every d1 commandThis PR adds a wrangler banner to the start of every D1 command (except when invoked in JSON-mode)
For example:
v3.27.0
Compare Source
Minor Changes
#4877
3e7cd6e4
Thanks @magnusdahlstrand! - fix: Do not show unnecessary errors during watch rebuildsWhen Pages is used in conjunction with a full stack framework, the framework
build will temporarily remove files that are being watched by Pages, such as
_worker.js
and_routes.json
.Previously we would display errors for these changes, which adds confusing and excessive messages to the Pages dev output. Now builds are skipped if a watched
_worker.js
or_routes.json
is removed.#4901
2469e9fa
Thanks @penalosa! - feature: implemented Python support in WranglerPython Workers are now supported by
wrangler deploy
andwrangler dev
.#4922
4c7031a6
Thanks @dario-piotrowicz! - feature: add actx
field to thegetBindingsProxy
resultAdd a new
ctx
filed to thegetBindingsProxy
result that people can use to mock the productionExecutionContext
object.Example:
Patch Changes
e61dba50
Thanks @nora-soderlund! - fix: ensure d1 validation errors render user friendly messages#4907
583e4451
Thanks @mrbbot! - fix: mark R2 object and bucket not found errors as unreportablePreviously, running
wrangler r2 objects {get,put}
with an object or bucket that didn't exist would ask if you wanted to report that error to Cloudflare. There's nothing we can do to fix this, so this change prevents the prompt in this case.#4872
5ef56067
Thanks @rozenmd! - fix: intercept and stringify errors thrown by d1 execute in --json modePrior to this PR, if a query threw an error when run in
wrangler d1 execute ... --json
, wrangler would swallow the error.This PR returns the error as JSON. For example, the invalid query
SELECT asdf;
now returns the following in JSON mode:#4888
3679bc18
Thanks @petebacondarwin! - fix: ensure that the Pages dev proxy server does not change the Host headerPreviously, when configuring
wrangler pages dev
to use a proxy to a 3rd party dev server,the proxy would replace the Host header, resulting in problems at the dev server if it was
checking for cross-site scripting attacks.
Now the proxy server passes through the Host header unaltered making it invisible to the
3rd party dev server.
Fixes #4799
#4909
34b6ea1e
Thanks @rozenmd! - feat: add an experimentalinsights
command towrangler d1
This PR adds a
wrangler d1 insights <DB_NAME>
command, to let D1 users figure out which of their queries to D1 need to be optimised.This command defaults to fetching the top 5 queries that took the longest to run in total over the last 24 hours.
You can also fetch the top 5 queries that consumed the most rows read over the last week, for example:
Or the top 5 queries that consumed the most rows written over the last month, for example:
Or the top 5 most frequently run queries in the last 24 hours, for example:
#4830
48f90859
Thanks @Lekensteyn! - fix: listen on loopback for wrangler dev port check and loginAvoid listening on the wildcard address by default to reduce the attacker's
surface and avoid firewall prompts on macOS.
Relates to #4430.
#4907
583e4451
Thanks @mrbbot! - fix: ensurewrangler dev --log-level
flag applied to all logsPreviously,
wrangler dev
may have ignored the--log-level
flag for some startup logs. This change ensures the--log-level
flag is applied immediately.Updated dependencies [
148feff6
]:Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ 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 has been generated by Mend Renovate. View repository job log here.