question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Blazor "dotnet watch run" and "VS 2019 Preview" issues with .NET 5.0.1 update

See original GitHub issue

I have a Blazor project which was working fine. Few hours ago updated VS 2019 to the latest “Version 16.9.0 Preview 2.0”. I also updated "Microsoft.AspNetCore.Components.WebAssembly" Version="5.0.1" Nuget package. I have done several Clean, Rebuild even restarted VS 2019. But still getting the same outcome.

  1. Newly opened VS instance with Blazor project builds correctly no messages in the “Error List” window. dotnet watch run command works. Site opened in the browser.
  2. Smallest code change (only added a space) will result nearly 100 build errors in the “Error List” window, meanwhile got “Build succeeded” status message. Also if I start the application from VS (press F5) it runs. But app works correctly in case of Server hosted mode. Blazor Web Assembly app looks very weird. It seems isolated CSS was not collected for the app.
  3. Already running ‘watch’ detects code change and also rebuilds the code with the error below:

Error in dotnet watch run console: C:\Program Files\dotnet\sdk\5.0.200-preview.20601.7\Sdks\NuGet.Build.Tasks.Pack\build\NuGet.Build.Tasks.Pack.targets(221,5): error : The given key 'tfm_raw' was not present in the dictionary.

As I know .NET 5.0.1 update was released recently. But I think it should be a “final” package not a preview? Because checking installed apps on my computer VS was installed a Preview package.

image

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:2
  • Comments:17 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
zkatcommented, Dec 14, 2020

@majorimi the patch has been merged into the appropriate preview branches for VS and .NET SDK, so this should be fixed with the next preview. 😃

1reaction
zkatcommented, Dec 10, 2020

No it’s definitely a bug, don’t get me wrong! I’m gonna work on getting this PR merged ASAP so we can get you unblocked 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Weird errors problem with dotnet watch with blazor/wasm.
I have a really annoying problem with dotnet watch and blazor/wasm. I have a solution in which I have multplie projects, for example...
Read more >
ASP.NET Core updates in .NET 5 Preview 8
NET 5 Preview 8 is now available and is ready for evaluation. Here's what's new in this release: Azure Active Directory authentication with ......
Read more >
.NET 5.0, VS2019 Preview and C# 9.0 for ASP .NET Core ...
This means that a manual installation of client-side Blazor is not required when using this preview version of Visual Studio. However, you ...
Read more >
Upgrading your .NET projects with Visual Studio - .NET Blog
The .NET Upgrade Assistant is now available as an experimental extension in Visual Studio to easily enable to update your apps and projects ......
Read more >
Upgrade Your ASP.NET Core (3.1 or 5) Project to .NET 6
NET Core projects 3.1 and 5 to . NET 6. We also look at the a fix for a potential error with ASP....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found