Skip to content

Fix Cloudflare tunnel crash errors when stopping app dev on Windows - #9065

Merged
isaacroldan merged 1 commit into
mainfrom
codex/fix-windows-tunnel-shutdown
Nov 4, 2026
Merged

isaacroldan merged 1 commit into
mainfrom
codex/fix-windows-tunnel-shutdown

Conversation

@isaacroldan

Copy link
Copy Markdown
Contributor

WHY are these changes introduced?

Stopping a working app dev session on Windows can report that the Cloudflare tunnel crashed. The final process-tree cleanup kills the tunnel without marking its exit as an expected stop.

WHAT is this pull request doing?

Stop the managed tunnel through the dev session's abort signal before process-tree cleanup. Also release it when preparation, process setup, or the session fails. Keep reporting unexpected tunnel failures.

No changeset is included in this PR; the stable/5.0 PR includes one.

How to manually test your changes?

  1. On Windows, run pnpm shopify app dev --path <app-directory> from this checkout with a linked app.
  2. Wait for the tunnel to connect and confirm that the app preview works.
  3. Press q. Confirm that the session stops without the Cloudflare "process crashed after stablishing a connection" error.
  4. Start the session again and stop it with Ctrl+C. Confirm the same result.

Validation

  • Five new lifecycle regression cases fail before the fix and pass after it.
  • 86 related tests pass, including the subprocess shutdown tests.
  • App type check, changed-file ESLint, and Prettier checks pass.
  • Live Windows validation is not yet complete.

Checklist

  • I've considered possible cross-platform impacts (Mac, Linux, Windows)
  • I've considered possible documentation changes
  • I've considered analytics changes to measure impact
  • The change is user-facing — I've identified the correct bump type and added a changeset

@github-actions github-actions Bot added the no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users. label Nov 4, 2026
@isaacroldan
isaacroldan marked this pull request as ready for review November 4, 2026 11:47
@isaacroldan
isaacroldan requested a review from a team as a code owner November 4, 2026 11:47
@isaacroldan
isaacroldan added this pull request to the merge queue Nov 4, 2026
Merged via the queue into main with commit bae9410 Nov 4, 2026
29 checks passed
@isaacroldan
isaacroldan deleted the codex/fix-windows-tunnel-shutdown branch November 4, 2026 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants