Skip to content

Skip stale bundles during dev server reload to avoid redundant restarts#14151

Merged
dario-piotrowicz merged 1 commit into
mainfrom
dario/improve-remote-bindings-reloading
Jun 2, 2026
Merged

Skip stale bundles during dev server reload to avoid redundant restarts#14151
dario-piotrowicz merged 1 commit into
mainfrom
dario/improve-remote-bindings-reloading

Conversation

@dario-piotrowicz

Copy link
Copy Markdown
Member

This PR fixes a thing I noticed with remote bindings, the fact that if the user repeatedly makes changes and saves their config file, their dev server becomes unresponsive as it reloads fully the remote proxy for every single save, consequently.
With this PR changes instead, only the last save actually triggers the full reload.

It's clearer to show the issue, see the videos below (pay attention on when the wrangler.jsonc file is saved by looking at it's tab):

Before:

before.mp4

After:

after.mp4

  • 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: bugfix

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

@changeset-bot

changeset-bot Bot commented Jun 2, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 2ee7bc0

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

This PR includes changesets to release 4 packages
Name Type
wrangler Patch
@cloudflare/vite-plugin Patch
@cloudflare/vitest-pool-workers Patch
@cloudflare/wrangler-bundler 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

@ask-bonk

ask-bonk Bot commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

UnknownError: ProviderInitError

github run

@ask-bonk

ask-bonk Bot commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

@dario-piotrowicz Bonk workflow failed. Check the logs for details.

View workflow run · To retry, trigger Bonk again.

@github-actions

github-actions Bot commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

✅ All changesets look good

@pkg-pr-new

pkg-pr-new Bot commented Jun 2, 2026

Copy link
Copy Markdown
create-cloudflare

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

@cloudflare/deploy-helpers

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

@cloudflare/kv-asset-handler

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

miniflare

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

@cloudflare/pages-shared

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

@cloudflare/unenv-preset

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

@cloudflare/vite-plugin

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

@cloudflare/vitest-pool-workers

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

@cloudflare/workers-editor-shared

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

@cloudflare/workers-utils

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

wrangler

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

@cloudflare/wrangler-bundler

npm i https://pkg.pr.new/@cloudflare/wrangler-bundler@14151

commit: 2ee7bc0

@dario-piotrowicz dario-piotrowicz force-pushed the dario/improve-remote-bindings-reloading branch 2 times, most recently from 25b8ae3 to c3e27f0 Compare June 2, 2026 16:22
@dario-piotrowicz dario-piotrowicz force-pushed the dario/improve-remote-bindings-reloading branch from c3e27f0 to 2ee7bc0 Compare June 2, 2026 16:48
@dario-piotrowicz dario-piotrowicz marked this pull request as ready for review June 2, 2026 17:04
@workers-devprod workers-devprod requested review from a team and petebacondarwin and removed request for a team June 2, 2026 17:05
@workers-devprod

workers-devprod commented Jun 2, 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 5 additional findings.

Open in Devin Review

@petebacondarwin petebacondarwin 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.

Nice work @dario-piotrowicz !

@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 Jun 2, 2026
@dario-piotrowicz dario-piotrowicz merged commit 7949f81 into main Jun 2, 2026
63 checks passed
@dario-piotrowicz dario-piotrowicz deleted the dario/improve-remote-bindings-reloading branch June 2, 2026 21:53
@github-project-automation github-project-automation Bot moved this from Approved to Done in workers-sdk Jun 2, 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