-
Notifications
You must be signed in to change notification settings - Fork 10k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BlazorWasmDebuggingExtension cannot find 'Microsoft.AspNetCore.App' version '5.0.0' #31653
Comments
cc: @captainsafia |
@niem94 So the Blazor WASM Debugging extension uses the .NET installer extension to ensure that there is a runtime installed before running. Have you ensured that the extension is installed? It should be included automatically when you install the debugging extension but something might've happened there. |
@captainsafia Yes, I did notice that ".NET Install Tool for Extension Authors" was installed automatically, and I have also tried removing ~/.vscode/extensions to see if that had any effect. |
I've got 5.0.5 SDK installed and get same error. I just installed 5.0.0 SDK side by side and restarted VS Code, same error. MacOS, C# 1.23.11, WASM Debug 1.0.0, .NET Install Tool 1.0.0 |
Are your problem also with hosted blazor wasm or with normal wasm? :-) |
Normal WASM |
The culprit might be related to our OS then. #MacOSLife. @captainsafia I hope someone on the team is able to prioritize this — would love to be able to enjoy the new debugging experience :-) |
No, I get the same issue on Linux. |
Hm -- I can repro this now.
So, the dotnet installed on your machine doesn't affect the problem here since it relies on the one installed by the installer.
The problem is that that the extension is only installing the M.N.A shared framework and not M.A.A as well now.
It appears that the .NET Installation extension recently added support for a new This is my hunch at the moment but it aligns with the behavior I'm seeing. There's still some ❓ since it doesn't look like the extension has been released for a while so not sure why those changes would be picked up (ref). |
Thanks for contacting us. |
@captainsafia thanks, this lets me move the missing runtime manually as a fix until someone at the team gets this sorted :-) I did this on MacOS by copying the Hope this helps others having the same issue. Also, the debugging experience seems much more stable from my initial tries. Nice work! |
But it works on Windows with 5.0.5 installed? Why is that? |
@niem94 Glad the reasoning helping you get a workaround.
Not sure, ATM. Haven't gotten around to reproing on Windows (I dev mainly on macOS). I suspect that the install behavior is a little different between the two. |
Can you direct me to the source code for the extension? |
I've installed the 1.0.1 version with the above fix but still not working. I notice the runtime extension is only downloading the MNA runtime not MAA one still. If I manually copy MAA to the extension .dotnet folder it works. MacOS |
The 1.0.1 fixes another bug where the installation failed at all and adds a workaround to use the debug proxy launched via the middleware as a fallback. This issue still needs to be resolved since the .NET tool installation extension doesn't support installing the M.A.A runtime yet. |
I had been using the debugger just fine until this week. Now I'm receiving the Invalid URL: undefined error. I'm on MacOS using .NET Core 5.0.5. I tried your workaround and it didn't change anything for me. Are there any other ideas folks can throw at me to help track this down? FWIW, the old debugging method "open /Applications/Google\ Chrome.app --args --remote-debugging-port=9222" still works. Not sure if that provides any clues. Thanks. |
Can you link your launch.json config? I remember i had to make some changes there as well, so i might be able to spot why if i can compare them :-) Mine looks like this: {
"version": "0.2.0",
"configurations": [
{
"name": "Launch and Debug Standalone Blazor WebAssembly App",
"type": "blazorwasm",
"request": "launch",
"hosted": true,
"cwd": "${workspaceFolder}/src/Presentation/Web/Server",
"program": "${workspaceFolder}/src/Presentation/Web/Server/bin/Debug/net5.0/EcosystemMapGenerator.Presentation.Web.Server.dll"
}
]
} |
I didn't change the launch.json file at all. Although my project/config is unchanged from dotnet new, I committed to a repo anyway just in case. https://github.com/bbuchanan/vscode-blazor-debug I tried your changes and receiving errors about launching. I'm not hosted though |
@bbuchanan I just tested your repo locally. It works with no problems on my end. So I am really not sure why it doesn't on your end. Im not sure it is related to this issue at all. My only suggestion would be to remove |
I suspect it's definitely something on my machine. I was redirected here from another site because they thought this might be related, but you're probably right, it's different. I'm getting the same error as @ar0311 only on Mac. I suppose I'm just looking for ideas to help track down what in the hell happened. I'm stuck! I completely removed VS Code and all extensions, destructively. I even went so far as to create a brand new user account on my machine. Nothing has given me satisfaction and I don't really know where things are going wrong. Any suggestions to help me track this down? |
@bbuchanan The issue @ar0311 ran into is an actual bug. I'm working on investigating it and following up with a fix. I had supposed that the workaround provided above might resolve the issue. In the absence of that, moving back to the two-step debugging process will always do the trick.
|
Thank you @captainsafia. That seems to get me working for now. I'm still absolutely perplexed as to what could have changed to make it stop working. Do you have any insight on how I might gather where in the process this is breaking down? I'd still like to figure it out, just not sure where to begin. Thank you again, this workaround does help immensely! |
Yes, so about two months ago, we shipped an update to the debugging experience in Blazor. It introduced a new extension that was responsible for launching the debugging proxy on the user's local machine and returning the host the debug proxy is running on. This extension depended on another extension that would download the .NET runtime onto the users machine (since the debugging proxy needs it to run). Recently, there was a behavior change in the extension and it no longer installs the correct runtime, the launching of the debug proxy fails, and the extension returns back I pushed a fallback for this but it will be fully shipped in the next release of the C# extension. |
Great to hear, I've been hitting this issue as well. Is there an estimate at all for the next release? |
AFAIK, the releases happen on an as-needed basis so I'll have to follow-up to see how things are rolling there. |
Thank you very much! Our team (and I'm sure many others) would appreciate an update. |
@captainsafia Wanted to check back in if there's an ETA for this release? |
@lucaswalter We're working on inserting a couple more changes before making a release. Conservatively, I'd say before the EoM. |
This issue should be resolved now with the latest version of the C# extension (v.1.23.12). |
Moved from dotnet/vscode-csharp#4489 (comment)
There seems to be problems with the new Microsoft.AspNetCore.Razor.VSCode.BlazorWasmDebuggingExtension. I have dotnet on the path, but it throws this error when trying to attach to a hosted Blazor Webassembly app.
Here is proof dotnet is on the path with the required framework:
This is my launch configuration:
The text was updated successfully, but these errors were encountered: