Packages

miniflare

4.20260730.0 · 30 Jul 2026MIT57.5M / weekRepositoryHomepagenpmAtom feed

Your version

4.20260430.0

30 Apr 2026Where it was published

4.20260730.0 is the newest release of 4.x.

In short

4 new4 fixed1 internal

Release note

Minor Changes

  • Hard fail on Node.js < 22

    Wrangler no longer supports Node.js 20.x, as it reached end-of-life on 2026-04-30. The minimum supported Node.js version is now 22.0.0. See github.com/nodejs/release.

  • Fix Hyperdrive binding issue where some customers are unable to connect to local databases using wrangler dev

    • Skips creating a local TCP proxy server for Hyperdrive bindings when SSL is not enabled, connecting directly to the database instead. This avoids connection refused errors caused by firewall rules or proxy port binding issues on Windows/macOS.

  • Add restart from step support for local Workflows development

    Workflow instances can now be restarted from a specific step in local development. When restarting from a step, all earlier steps preserve their cached results and replay instantly, while the target step and everything after it re-execute.

    The WorkflowInstance.restart() method now accepts an optional { from: { name, count?, type? } } parameter to specify which step to restart from.

  • Support V2 protocol for module fallback service

    When the new_module_registry compatibility flag is set, requests sent to unsafeModuleFallbackService() use a different protocol. Miniflare now supports both protocols and exports a parseModuleFallbackRequest() utility to ease handling.

Patch Changes

  • Expose send_email bindings from getPlatformProxy()

    Projects developing in Node can now access send_email bindings from the platform proxy. This supports the plain-object MessageBuilder API locally, so calls like env.EMAIL.send({ from, to, subject, text }) no longer fail because the binding is missing.

  • Normalise typed array subclasses in devalue serialization

    Node.js Buffer extends Uint8Array but isn't available in all runtimes. When a Buffer was passed through the proxy serialization bridge (e.g. as a D1 bind parameter via getPlatformProxy()), the reviver would fail because "Buffer" isn't in the allowed constructor list and may not exist on globalThis in workerd.

    The reducer now normalises subclass constructor names to the nearest standard typed array parent before serialization, matching structured clone behaviour.

  • Gracefully handle a missing assets directory by starting with zero assets

    Previously, configuring Miniflare with an assets.directory that did not exist on disk would cause the asset services to fail to start. This is a common situation during wrangler dev when the assets directory is a build output that hasn't been generated yet.

    Now, when the configured assets directory does not exist, Miniflare creates an empty temporary directory and starts the asset services with zero assets. Once the real directory is created and setOptions() is called (e.g. triggered by the file watcher), Miniflare reloads and begins serving the actual assets.

  • Prepares router-worker for a more gradual rollout by refactoring and separating out the invocation from the business logic. In the future, this will provide space for us to route requests to new versions of router-worker based on their plan, but should make no functional difference today.

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.