Packages

wrangler

4.164.0 · 17 Nov 2026MIT OR Apache-2.049.3M / weekRepositoryHomepagenpmAtom feed

Your version

4.72.0

10 Mar 2026Where it was published

4.167.0 is the newest release of 4.x.

In short

1 security2 new3 fixed2 internal

  • Security

    Bump node-forge to ^1.3.2 to address security vulnerabilities

Release note

Minor Changes

  • Add support for inheritable bindings in type generation

    When using wrangler types with multiple environments, bindings from inheritable config properties (like assets) are now correctly inherited from the top-level config in all named environments. Previously, if you defined assets.binding at the top level with named environments, the binding would be marked as optional in the generated Env type because the type generation didn't account for inheritance.

    Example:

    {
        "assets": {
            "binding": "ASSETS",
            "directory": "./public"
        },
        "env": {
            "staging": {},
            "production": {}
        }
    }

    Before this change, ASSETS would be typed as ASSETS?: Fetcher (optional). Now, ASSETS is correctly typed as ASSETS: Fetcher (required). This fix currently applies to the assets binding, with an extensible mechanism to support additional inheritable bindings in the future.

  • Enable container egress interception in local dev without the experimental compatibility flag

    Container local development now always prepares the egress interceptor sidecar image needed for interceptOutboundHttp(). This makes container-to-Worker interception available by default in Wrangler, Miniflare, and the Cloudflare Vite plugin.

Patch Changes

  • Security

    Bump node-forge to ^1.3.2 to address security vulnerabilities

    node-forge had ASN.1 unbounded recursion, OID integer truncation, and ASN.1 validator desynchronization vulnerabilities. This is a bundled dependency used for local HTTPS certificate handling.

  • Fix wrangler d1 execute --json returning "null" (string) instead of null (JSON null) for SQL NULL values

    When using wrangler d1 execute --json with local execution, SQL NULL values were incorrectly serialized as the string "null" instead of JSON null. This produced invalid JSON output that violated RFC 4627. The fix removes the explicit null-to-string conversion so NULL values are preserved as proper JSON null in the output.

  • Strip query strings from module names before writing to disk

    When bundling modules with query string suffixes (e.g. .wasm?module), the ? character was included in the output filename. Since ? is not a valid filename character on Windows, this caused an ENOENT error during wrangler dev. This was particularly visible when using Prisma Client with the D1 adapter, which imports .wasm?module files.

    The fix strips query strings from module names before writing them to disk, while preserving correct module resolution.

  • Make remote dev exchange_url optional

    The edge-preview API's exchange_url is now treated as optional. When unavailable or when the exchange fails, the initial token from the API response is used directly. The prewarm step and inspector_websocket have been removed from the remote dev flow in favour of tail_url for live logs.

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.