• python
  • javascript
  • reactjs
  • sql
  • c#
  • java
Facebook Twitter Instagram
Devs Fixed
  • python
  • javascript
  • reactjs
  • sql
  • c#
  • java
Devs Fixed
Home ยป Resolved: Can not publish Blazor wasm to azure anymore

Resolved: Can not publish Blazor wasm to azure anymore

0
By Isaac Tonny on 18/06/2022 Issue
Share
Facebook Twitter LinkedIn

Question:

i just wanted to publish my changes to my .Net6 blazor wasm app to azure to update it like i did a dozen times. Since yesterday that does not work anymore. I can build and run it locally with no problem but when I try to publish it, I get a window telling me:

Publish has encountered an error. Build failed. Check the Output window for more details. A diagnostic log has been written to the following location: "C:\Users\user\AppData\Local\Temp\tmpE865.tmp"


Content of that file:

16.06.2022 08:20:08 System.AggregateException: One or more errors occurred. —> Microsoft.WebTools.Shared.Exceptions.WebToolsException: Build failed. Check the Output window for more details. — End of inner exception stack trace — —> (Inner Exception #0) Microsoft.WebTools.Shared.Exceptions.WebToolsException: Build failed. Check the Output window for more details.<— Microsoft.WebTools.Shared.Exceptions.WebToolsException: Build failed. Check the Output window for more details. ===================


Console Output:

C:\Program Files\dotnet\sdk\6.0.400-preview.22301.10\Sdks\Microsoft.NET.Sdk.BlazorWebAssembly\targets\Microsoft.NET.Sdk.BlazorWebAssembly.6_0.targets(614,5): Error MSB6006: "dotnet.exe" exited with code 1.


Tried fetching older versions of the code that I successfully published a few days ago. Still does not work. My coworker can still publish the same code.
But I can publish my API Backend…so this error seems to be related to blazor wasm.
Tried this with the latest release of VS 2022 and just gave the preview version a try – no luck.
I’ve also done a repair installation of the .Net 6 SDK.
Edit: I’ve tried to publish my project to a folder and got the same error. So no relation to azure. Then I’ve created a new blank Blazor app…I can publish this one to a folder with no error. So my project is somehow broken…but even older code can’t be published. This is so odd…

Answer:

@XSharp is correct. We had same issue started occurring yesterday. We were using version ‘6.0.x’ of DotNet which seems to have started using version ‘6.0.301’ that seems to be causing this issue. Force it to use the previous version ‘6.0.106’ instead
Just add the following at the top of your tasks in your YAML
Looks like someone has reported it as an issue when having a blank space in your project path: https://github.com/dotnet/core/issues/7548

If you have better answer, please add a comment about this, thank you!

azure blazor-webassembly
Share. Facebook Twitter LinkedIn

Related Posts

Resolved: navigate and redirect not redirecting to path in react router

24/03/2023

Resolved: Time Complexity: Find the number of people who know a secret leetcode 2327

24/03/2023

Resolved: Best way to create 3d matrix of variables in PULP

24/03/2023

Leave A Reply

© 2023 DEVSFIX.COM

Type above and press Enter to search. Press Esc to cancel.