Skip to content

CompilerServer: server failed - server rejected the request due to analyzer/generator issues #334

@twsouthwick

Description

@twsouthwick

Actual behavior

Tried to add cswin32 to a net6 project. Works fine with 0.1.422-beta but fails with 0.1.506-beta with the following error when attempting to build (can provide binlog if it's helpful):

CompilerServer: server failed - server rejected the request due to analyzer / generator issues 'analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Buffers.dll' has MVID '081c3ecc-60b8-44f9-a6aa-b9d202311a05' but loaded assembly 'System.Buffers, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' has MVID '670214a0-e284-4aed-8358-603a9cdf4812', analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Memory.dll' has MVID '364de6aa-3638-4f0c-b478-eff7d6f86309' but loaded assembly 'System.Memory, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' has MVID '871f5bca-4f8d-4e1a-8859-90daa83768d9', analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Numerics.Vectors.dll' has MVID 'bdab00d2-0f43-4b68-af83-6c4884136dab' but loaded assembly 'System.Numerics.Vectors, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' has MVID 'fff565b5-4ae2-407c-9e6a-d022e207345f', analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Runtime.CompilerServices.Unsafe.dll' has MVID 'd22a1fa6-8134-4c26-bb36-e67aceee55b8' but loaded assembly 'System.Runtime.CompilerServices.Unsafe, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' has MVID 'b9b92192-a4ed-4258-92b4-f5aed592130e', analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Text.Encodings.Web.dll' has MVID 'ff11d640-d619-4ea0-8fda-ab7888f8535e' but loaded assembly 'System.Text.Encodings.Web, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' has MVID '5629a5af-5f5b-4168-8a45-13e3f4da61ae', analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Text.Json.dll' has MVID '815ff95f-4d6a-463f-a6a3-be490e0514aa' but loaded assembly 'System.Text.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' has MVID 'aa7bd58c-3492-4794-8207-985ae5bc968a', analyzer assembly 'C:\Users\twsou\.nuget\packages\microsoft.windows.cswin32\0.1.506-beta\analyzers\cs\System.Threading.Tasks.Extensions.dll' has MVID '619062a8-972f-4ae5-bbee-e36ac541d14f' but loaded assembly 'System.Threading.Tasks.Extensions, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' has MVID '433a1b5e-6c03-48ff-9450-b56d86443657'' - 2c965cac-8fd7-42a0-af45-17a0ab85c73d

Expected behavior

Expect the analyzer to load

Repro steps

  1. NativeMethods.txt content:
CreateFile
  1. NativeMethods.json content (if present):
  1. Any of your own code that should be shared?

Context

  • CsWin32 version: 0.1.506-beta
  • Win32Metadata version (if explicitly set by project):
  • Target Framework: [e.g. netstandard2.0] net6.0
  • LangVersion (if explicitly set by project): [e.g. 9]

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions