Skip to content

Blazor WASM "Debug Adapter" fail to handle breakpoints when a Web Worker is present #98208

Open

Description

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

When a Web worker is created in a Blazor WebAssembly project the debugger(Visual Studio 2022) will stop working since the "Debug Proxy" seems to disconnect. Once the web worker is active unset/set breakpoints in Visual Studio 2022 will display Unable to retrieve source content.
example project: BlazorWasmDebugBrokenWithWebWorker

Expected Behavior

The breakpoint in Visual Studio 2022 should be set without any error message.

Steps To Reproduce

How to reproduce

  1. Run the example project in the VS2022 debugger.
  2. Open the "Counter"-page <- This will create a web worker
  3. Set a breakpoint in the "IncrementCount" method
  4. Click the "Click me" button.
  5. The breakpoint will be hit -> Press "continue" in the VS2022 debugger.
  6. Uncheck the breakpoint and then set it again on the same line.

Result

The debugger will stop in javascript and display Unable to retrieve source content

Expected result

The breakpoint should be set without any error message.

Exceptions (if any)

No response

.NET Version

8.0.101

Anything else?

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions