-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
MSBuildWorkspace does not cleanly load blazorwasm project #72015
Comments
@jaredpar @chsienki @jjonescz I'm wondering if this was broken by #71579. The generator being loaded from the SDK is one that still expects the ExternalAccess to be there, but we don't have it any more for newer Roslyn builds. This seems like fallout for how the razor generator is expected to load:
|
If I read the error message correctly, the ExternalAccess.RazorCompiler dll is present, it just cannot implement internal CodeAnalysis interface anymore. I think we could just keep the IVT around to solve this (#71579 (comment)). |
@jjonescz Does that mean at this point the expectation is the core compiler binaries are always maintaining the APIs that the old ExternalAccess was accessing? |
Verified locally that the fix @jjonescz proposes will resolve this issue. |
Hm, good question. It should be enough if we keep them as stubs (if we want to remove or rename them in the future) - because the razor compiler doesn't rely on them working (the machinery was supposed to be used by razor IDE to get design-time outputs out of the razor compiler). |
When can we expect the fix to be released? |
Visual Studio 17.10 Preview 2 (and .NET SDK 8.0.300 I think). In about a month. |
Doesn't it affect also Visual Studio / MSBuild 17.9? My Blazor project has been broken since 17.9 when running |
I don't think that's possible, the issue described here was introduced in VS 17.10 Preview 1 by #71579 which didn't get into VS 17.9 nor SDK 8.0.200.
The IVT has never been removed from the 17.9 branch, so there's nothing to fix there:
|
@jonashendrickx Can you share the error you're getting just to make sure we're discussing the same bug? |
@jasonmalinowski https://github.com/bitwarden/passwordless-server/actions/runs/7989471492/job/21816103177 It's here saying the directives are unused and cannot be removed, but they are in fact being used. The source code for workflow below: https://github.com/bitwarden/passwordless-server/tree/fix/is-app-id-available-endpoint-is-returning-a-500-in-admin-console
If you are in doubt, create a new Blazor project, apply an editorconfig with |
Version Used: 4.10 Preview 1
Reported in #69225
Steps to Reproduce:
Expected Behavior:
Project loads without any workspace diagnostics and compilation reports no compiler diagnostics.
Actual Behavior:
Compilation reports "CS0246: The type or namespace name {'csharp_blazor_project'|'App'} could not be found (are you missing a using directive or an assembly reference?)"
Possibly unrelated
I noticed that the C# extension in VS Code reports the following when opening the blazorwasm project.
The text was updated successfully, but these errors were encountered: