Skip to content
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

Generator 'RazorSourceGenerator' failed to generate source #8656

Closed
NikolaMilosavljevic opened this issue May 1, 2023 · 0 comments · Fixed by #8657
Closed

Generator 'RazorSourceGenerator' failed to generate source #8656

NikolaMilosavljevic opened this issue May 1, 2023 · 0 comments · Fixed by #8657

Comments

@NikolaMilosavljevic
Copy link
Member

The BlazorWasm test surfaces an issue with the RazorSourceGenerator. It appears that is has bundled an SBRP package with it and is trying to execute code from it.

CSC : warning CS8785: Generator 'RazorSourceGenerator' failed to generate source. It will not contribute to the output and compilation errors may occur as a result. Exception was of type 'BadImageFormatException' with message 'Could not load file or assembly 'Microsoft.Extensions.ObjectPool, Version=6.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. Reference assemblies cannot be loaded for execution. (0x80131058)' [/repos/dotnet/test/Microsoft.DotNet.SourceBuild.SmokeTests/bin/Release/net8.0/projects-202304210321071372/WebScenarioTests_BlazorWasm_CSharp/WebScenarioTests_BlazorWasm_CSharp.csproj] [/repos/dotnet/build.proj]

We've added a patch for this issue in installer repo: dotnet/installer#16260

Fix in razor repo is required.

@ghost ghost added the untriaged label May 1, 2023
@ghost ghost removed the untriaged label May 2, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Jun 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant