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

Bugreport: System.TypeInitializationException: The type initializer for 'LiquidTemplate' threw an exception. after updating to v14.2.0.0 #5035

Open
sbma24 opened this issue Nov 21, 2024 · 8 comments

Comments

@sbma24
Copy link

sbma24 commented Nov 21, 2024

I just updated to the recent version 14.2.0.0. Every time, I want to generate the output or files I get the error

System.TypeInitializationException: The type initializer for 'LiquidTemplate' threw an exception.
 ---> System.IO.FileNotFoundException: Could not load file or assembly 'Fluid, Version=2.12.0.0, Culture=neutral, PublicKeyToken=51cdb8c1938e4789'. The system cannot find the file specified.
File name: 'Fluid, Version=2.12.0.0, Culture=neutral, PublicKeyToken=51cdb8c1938e4789'
Check if .NET Core is installed and 'dotnet' is globally available.
@IODav
Copy link

IODav commented Nov 21, 2024

Same issue after updating

@N3uR02812
Copy link

Same issue. With v14.1.0.0 it still works

@AlexRoth01
Copy link

Same for me, we try to generate output files for a .net 8 project.

But I found a workaround:
If you look at the installation directory of NSwag Studio, you will find the Fluid.dll assembly in the Net90 subdirectory, but not in the Net80 subdirectory!

I've therefore copied this file from NET90 to NET80, and after that the file generation works again.

Hope that helps

@lahma
Copy link
Collaborator

lahma commented Nov 21, 2024

Don't know what happens with the studio installer, but try running repair. The installer is available on the release page: https://github.com/RicoSuter/NSwag/releases/tag/v14.2.0

@banderberg
Copy link

Having the same problem. Using 'Repair' doesn't work, the installer says it ended prematurely.

@zif-trimble
Copy link

Same for me, we try to generate output files for a .net 8 project.

But I found a workaround: If you look at the installation directory of NSwag Studio, you will find the Fluid.dll assembly in the Net90 subdirectory, but not in the Net80 subdirectory!

I've therefore copied this file from NET90 to NET80, and after that the file generation works again.

Hope that helps

This works

@RicoSuter
Copy link
Owner

RicoSuter commented Nov 21, 2024

Fresh install seems fine...

image

image

Seems to be a problem with the WIX installer, and we had this in the past:
#1750 (comment)

@eddex
Copy link

eddex commented Nov 21, 2024

Uninstall and re-install fixed it for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants