runtime: Frame not in module when hitting a breakpoint in Blazor WASM
Is there an existing issue for this?
- I have searched the existing issues
Describe the bug
After upgrading to Visual Studio 17.6.0 and 17.6.1 the debugger shows me a Source Not Available page with the body:
Frame not in module
The current stack frame was not found in a loaded module. Source cannot be shown for this location.
The curious thing is that in the .razor file the breakpoints selected before executing the application are kept without warnings, but if I add one while the application is running, it appears with the warning: “The breakpoint will not currently be hit. Unbound breakpoint”.
When I open the debug window “Modules” I can check that the module “Application.server.dll” has the status “Symbols loaded” and that the “symbol file” is correct.
I have tried deleting the .obj and .bin directories, I have tried with .net 6 and .net 7 (with their corresponding updated NuGet packages), I have tried with different browsers, and in all of them, the error is the same.
When debugging no error appears in the Output window.
The curious thing is that if I create a new application with the wizard, there is no problem and Visual Studio stops at the line in the .razor file. I have analyzed both projects and I do not see what could be the cause of my main project causing this problem.
Expected Behavior
- That Visual Studio allows me to add breakpoints without displaying the error “The breakpoint will not currently be hit. Unbound breakpoint”.
- Visual Studio stops at the correct line in the .razor file once it hits the breakpoint.
Steps To Reproduce
No response
Exceptions (if any)
No response
.NET Version
7.0.302
Anything else?
- ASP.NET Core version: 6.0.16 or 7.0.5
- Visual Studio 17.6.1
.NET SDK:
Version: 7.0.302
Commit: 990cf98a27
Runtime Environment:
OS Name: Windows
OS Version: 10.0.22621
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\7.0.302\
Host:
Version: 7.0.5
Architecture: x64
Commit: 8042d61b17
.NET SDKs installed:
3.1.426 [C:\Program Files\dotnet\sdk]
5.0.408 [C:\Program Files\dotnet\sdk]
6.0.311 [C:\Program Files\dotnet\sdk]
7.0.302 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
Microsoft.AspNetCore.All 2.1.24 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.28 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.29 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.24 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.28 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.29 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.20 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.23 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.32 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 5.0.17 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.16 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.24 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.26 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.28 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.29 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.20 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.23 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.32 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 5.0.12 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 5.0.17 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.12 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.15 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.16 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.1.20 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 3.1.23 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 3.1.32 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 5.0.12 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 5.0.17 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.15 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.16 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Other architectures found:
x86 [C:\Program Files (x86)\dotnet]
registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x86\InstallLocation]
Environment variables:
Not set
global.json file:
Not found
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 43 (10 by maintainers)
Commits related to this issue
- fix: Blazor sources sometimes being missing Ref https://github.com/dotnet/runtime/issues/86754 A true fix is being applied in .net, but this will take time to trickle down. — committed to microsoft/vscode-js-debug by connor4312 a year ago
- fix: Blazor sources sometimes being missing (#1716) Ref https://github.com/dotnet/runtime/issues/86754 A true fix is being applied in .net, but this will take time to trickle down. — committed to microsoft/vscode-js-debug by connor4312 a year ago
We have a fix for this also coming on the debugger side which should be in the next release, but in the mean time, if you want to get things working right away, you can replace the files in C:\Program Files{Your VS install dir}\Common7\IDE\CommonExtensions\Microsoft\JSDiagnostics\Debugger\DebugAdapter with the files in dist.zip. That should get you the fix right away (use at your own risk, since this is not the official way to upgrade the debugger, though it should work).
I currently have the same issue. @EricCornelson dist.zip file replacement makes debugging breakpoints on my Web Assembly Client project work again. Can this thread be updated when it is fixed in a new release?
@joseangelmt I need more help to reproduce/understand what may be happening. First, can you share the code? Second, can you share the file: C:\Users[USER_NAME]\AppData\Local\Temp\visualstudio-js-debugger.txt Third, can you share the nuget packages that you are using and the versions in your projects?
Thanks