Support true VS Code “launch” debugging for Workers with reliable breakpoints #14120
mannok
started this conversation in
Feature Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Cloudflare Workers would benefit from first-class VS Code launch-mode debugging, where developers can press F5 and have the full debug session start automatically: local Worker runtime, debugger attachment, source-map resolution, breakpoint binding, and process cleanup.
Today, the documented workflow is primarily an attach experience: start
wrangler devseparately, then attach VS Code to the inspector. While attach debugging is useful, many developers expect the standard VS Codelaunchexperience provided by modern frameworks and runtimes.Desired Experience
src/index.ts.In other words, developers should not need to manually run
wrangler devfirst. The debug configuration should behave like a normallaunchtarget, even if Wrangler internally startsworkerdand VS Code attaches to an inspector.Why This Matters
Worker debugging currently involves several moving pieces:
wrangler devstarts the local runtime.workerdexposes the inspector.If any part of this chain is misaligned, developers can run into hollow/unbound breakpoints, attachment to the wrong inspector target, or lingering dev processes after debugging stops.
Requested Outcome
launch-style configuration for Workers.wrangler dev..dev.vars, compatibility flags, and local mode.Possible Implementation Paths
launch.jsonthat behaves like launch debugging while handling internal attach details..wrangler/tmpfiles.This would make Workers debugging feel much closer to the experience developers get from modern Node, frontend, and full-stack frameworks, where pressing F5 starts the app and breakpoints work by default.
Beta Was this translation helpful? Give feedback.
All reactions