-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
.Net 8 RC1 Regression: error BLAZORSDK1001: Unable to find '{dll list}' to be lazy loaded later. Confirm that project or package references are included and the reference is used in the project. #92965
Comments
Tagging subscribers to this area: @thaystg Issue DetailsDescriptionI upgrade exising Blazor WASM with lazy loaded assemblies project to .Net 8 SDK but I got this error when building it:
Reproduction Steps
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.0-rc.1.23421.29" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.0-rc.1.23421.29" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\RazorClassLibrary1\RazorClassLibrary1.csproj" />
</ItemGroup>
<ItemGroup>
<BlazorWebAssemblyLazyLoad Include="RazorClassLibrary1.dll" />
</ItemGroup>
</Project>
Rebuild started...
1>------ Rebuild All started: Project: RazorClassLibrary1, Configuration: Debug Any CPU ------
Restored C:\Users\LefebvreO\source\repos\BlazorApp1\RazorClassLibrary1\RazorClassLibrary1.csproj (in 290 ms).
Restored C:\Users\LefebvreO\source\repos\BlazorApp1\BlazorApp1\BlazorApp1.csproj (in 324 ms).
1>C:\Program Files\dotnet\sdk\8.0.100-rc.1.23455.8\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.RuntimeIdentifierInference.targets(311,5): message NETSDK1057: You are using a preview version of .NET. See: https://aka.ms/dotnet-support-policy
1>RazorClassLibrary1 -> C:\Users\LefebvreO\source\repos\BlazorApp1\RazorClassLibrary1\bin\Debug\net8.0\RazorClassLibrary1.dll
2>------ Rebuild All started: Project: BlazorApp1, Configuration: Debug Any CPU ------
2>C:\Users\LefebvreO\.nuget\packages\microsoft.net.sdk.webassembly.pack\8.0.0-rc.1.23419.4\build\Microsoft.NET.Sdk.WebAssembly.Browser.targets(368,5): error BLAZORSDK1001: Unable to find 'RazorClassLibrary1.dll' to be lazy loaded later. Confirm that project or package references are included and the reference is used in the project.
2>Done building project "BlazorApp1.csproj" -- FAILED.
========== Rebuild All: 1 succeeded, 1 failed, 0 skipped ==========
========== Rebuild started at 10:23 PM and took 10.150 seconds ========== Expected behaviorShould build without error Actual behaviorBuild error error BLAZORS Regression?Yes, it was working with .Net 7 Known WorkaroundsDisable assembly lazy loading ConfigurationSDK: 8.0.100-rc.1.23455.8 Other informationNo response
|
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsDescriptionI upgrade exising Blazor WASM with lazy loaded assemblies project to .Net 8 SDK but I got this error when building it:
Reproduction Steps
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.0-rc.1.23421.29" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.0-rc.1.23421.29" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\RazorClassLibrary1\RazorClassLibrary1.csproj" />
</ItemGroup>
<ItemGroup>
<BlazorWebAssemblyLazyLoad Include="RazorClassLibrary1.dll" />
</ItemGroup>
</Project>
Rebuild started...
1>------ Rebuild All started: Project: RazorClassLibrary1, Configuration: Debug Any CPU ------
Restored C:\Users\LefebvreO\source\repos\BlazorApp1\RazorClassLibrary1\RazorClassLibrary1.csproj (in 290 ms).
Restored C:\Users\LefebvreO\source\repos\BlazorApp1\BlazorApp1\BlazorApp1.csproj (in 324 ms).
1>C:\Program Files\dotnet\sdk\8.0.100-rc.1.23455.8\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.RuntimeIdentifierInference.targets(311,5): message NETSDK1057: You are using a preview version of .NET. See: https://aka.ms/dotnet-support-policy
1>RazorClassLibrary1 -> C:\Users\LefebvreO\source\repos\BlazorApp1\RazorClassLibrary1\bin\Debug\net8.0\RazorClassLibrary1.dll
2>------ Rebuild All started: Project: BlazorApp1, Configuration: Debug Any CPU ------
2>C:\Users\LefebvreO\.nuget\packages\microsoft.net.sdk.webassembly.pack\8.0.0-rc.1.23419.4\build\Microsoft.NET.Sdk.WebAssembly.Browser.targets(368,5): error BLAZORSDK1001: Unable to find 'RazorClassLibrary1.dll' to be lazy loaded later. Confirm that project or package references are included and the reference is used in the project.
2>Done building project "BlazorApp1.csproj" -- FAILED.
========== Rebuild All: 1 succeeded, 1 failed, 0 skipped ==========
========== Rebuild started at 10:23 PM and took 10.150 seconds ========== Expected behaviorShould build without error Actual behaviorBuild error error BLAZORS Regression?Yes, it was working with .Net 7 Known WorkaroundsDisable assembly lazy loading ConfigurationSDK: 8.0.100-rc.1.23455.8 Other informationNo response
|
In .NET 8 there is a change in how managed dlls are delivered to the browser. Serving |
Description
I upgrade exising Blazor WASM with lazy loaded assemblies project to .Net 8 SDK but I got this error when building it:
Reproduction Steps
Expected behavior
Should build without error
Actual behavior
Build error error BLAZORS
DK1001: Unable to find
Regression?
Yes, it was working with .Net 7
Known Workarounds
Disable assembly lazy loading
Configuration
SDK: 8.0.100-rc.1.23455.8
Running on 11 Enterprise 21H2
Processor: x64
Browser: Edge
Other information
No response
The text was updated successfully, but these errors were encountered: