Closed fabich closed 3 years ago
I found the issue - Swashbuckle CLI had an issue with our SwaggerHostFactory after the update.
dotnet : Unhandled exception. System.IO.FileLoadException: Could not load file or assembly 'Swashbuckle.AspNetCore.Swagger, Version=6.1.4.0, Culture=neutral, PublicKeyToken=62657d7474907593'. The located assembly's manifest definition does not match the assembly reference. (0x80131040)
For anyone who ran into this recently on version 6.1.4 and .net 5, installing Swashbuckle.AspNetCore.Annotations solved my issue.
can confirm, installing Swashbuckle.AspNetCore.Annotations also works for 6.3.0 and .net 6.
does not seem to help for 6.5.0 and .net 7.0.202 :/
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.4.0" />
<PackageReference Include="Swashbuckle.AspNetCore.Annotations" Version="6.4.0" />
<PackageReference Include="Swashbuckle.AspNetCore.Swagger" Version="6.4.0" />
This worked for me for swashbuckle.aspnetcore.cli
tool version 6.4.0
. @devio-at
I am facing the same problem for 6.5.0 and .NET 7.0. Any solution?
I am also facing the same problem for 6.5.0 and .NET 7.0.
Check that your .csproj has 6.5.0 references if you are using dotnet tool version 6.5.0. If you have e.g. 6.4.0 reference (dotnet web api template has that version), you will get error for Swashbuckle.AspNetCore.Swagger because the .dll file is there, but it is wrong version.
I opened a ticket for better error text https://github.com/domaindrivendev/Swashbuckle.AspNetCore/issues/2666
I am also facing the same problem for 6.5.0 and .NET 7.0. Any solution?
I am also facing the same issue for v6.5.0 & even for v6.4.0 and net7.0 even when I haven't installed Swashbuckle.AspNetCore.SwaggerGen NuGet package. I do have installed Swashbuckle.AspNetCore, Swashbuckle.AspNetCore.Newtonsoft
Can anyone help ?
Any update on this issue? I'm using .Net 8.0.100 with Swashbuckle.Aspnetcore version=6.5.0 and Cli version = 6.5.0. I installed Annotation version=6.5.0 as well still facing the same issue. I've added environment variable "DOTNET_ROLL_FORWARD=LatestMajor" also. Still no success!
Problem solved by switching to a fork of this project by @Havunen https://github.com/Havunen/DotSwashbuckle/
Hi
After updating the CLI from
5.4.1
to6.0.7
we are getting the following error on our GitHub Action build:Our GitHub Action:
The .csproj file:
Any idea what might cause this issue?