dotnet / AspNetCore.Docs

Documentation for ASP.NET Core
https://docs.microsoft.com/aspnet/core
Creative Commons Attribution 4.0 International
12.61k stars 25.3k forks source link

There was no runtime pack for Microsoft.AspNetCore.App available for the specified RuntimeIdentifier 'browser-wasm'. #20507

Closed ozanyasindogan closed 3 years ago

ozanyasindogan commented 3 years ago

Hello,

When I migrated my Asp.net Core 3.1 Hosted Blazor Webassembly Project to .Net 5 (Client, Server, Shared) I started to get at Server project below error message:

There was no runtime pack for Microsoft.AspNetCore.App available for the specified RuntimeIdentifier 'browser-wasm'. and directs me there: ` <!--

                                    ResolveRuntimePackAssets

Resolve assets from runtime packs.
============================================================
-->

<Target Name="ResolveRuntimePackAssets" DependsOnTargets="ResolveFrameworkReferences" Condition="'@(RuntimePack)' != ''">

<ResolveRuntimePackAssets FrameworkReferences="@(FrameworkReference)"
                          ResolvedRuntimePacks="@(ResolvedRuntimePack)"
                          UnavailableRuntimePacks="@(UnavailableRuntimePack)"
                          SatelliteResourceLanguages="$(SatelliteResourceLanguages)"
                          DesignTimeBuild="$(DesignTimeBuild)">
  <Output TaskParameter="RuntimePackAssets" ItemName="RuntimePackAsset" />
</ResolveRuntimePackAssets>

<ItemGroup>
  <ReferenceCopyLocalPaths Include="@(RuntimePackAsset)"
                           Condition="'$(CopyLocalLockFileAssemblies)' == 'true' and ('$(SelfContained)' == 'true' or '%(RuntimePackAsset.RuntimePackAlwaysCopyLocal)' == 'true')" />
</ItemGroup>

`

When I bring back to

it seems to compile but does not work properly. Why this is happening? [Enter feedback here] --- #### Document Details ⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.* * ID: b031caa0-c62b-37da-46c3-59043256cac2 * Version Independent ID: bdf98c9a-96f6-79fd-a650-5c0385d1a62b * Content: [Migrate from ASP.NET Core 3.1 to 5.0](https://docs.microsoft.com/en-us/aspnet/core/migration/31-to-50?view=aspnetcore-3.1&tabs=visual-studio) * Content Source: [aspnetcore/migration/31-to-50.md](https://github.com/dotnet/AspNetCore.Docs/blob/master/aspnetcore/migration/31-to-50.md) * Product: **aspnet-core** * Technology: **aspnetcore-migration** * GitHub Login: @scottaddie * Microsoft Alias: **scaddie**
guardrex commented 3 years ago

Hello @ozanyasindogan ... Best to open that for the product unit at ...

https://github.com/dotnet/aspnetcore/issues

ozanyasindogan commented 3 years ago

Ok, thanks

guardrex commented 3 years ago

@ozanyasindogan ... If you find out eventually that it is something we need to call out in the migration doc, open a new issue and ping me with a cross-link to your engineering issue and solution. We had a TON of updates this time around. It's possible ... perhaps even likely ... that we're missing one or a few things.