You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can't make the source generator works with my project. So, I downloaded the sources of refitter, opened the test solution, updated the NuGet packages, unloaded all the projects other than Net8, deleted the Generated folder, built the project and nothing, the project does not compile because the generated classes are not there. If I try the same thing with Net7, the classes are generated. There is zero output from the source generator.
The text was updated successfully, but these errors were encountered:
@plavoie-nms Thanks for taking the time to report this and the investigative steps you have taken.
I use this primarily for .NET 8.0 projects and have it running on several systems. I'm running on against v0.9.6
The source generator is a bit limited in the sense that it generates physical files so if there are any dependencies on those files in the project then the build will fail, the first time around. After building once, the generated files should appear and the build should work again
I just tested this with building using the .NET CLI and also from Visual Studio 2022. Visual Studio 2022 has a bit of magic to it as it can detect changes to the file and will execute the source generator in the background.
have you tried shutting down the .NET Build Servers -> dotnet build-server shutdown? I found this to be a necessary trick when developing source generators. I ran into situations now and then where the source generator just stopped working, and it wouldn't work again until I shut down the .NET Build Servers
Can't make the source generator works with my project. So, I downloaded the sources of refitter, opened the test solution, updated the NuGet packages, unloaded all the projects other than Net8, deleted the Generated folder, built the project and nothing, the project does not compile because the generated classes are not there. If I try the same thing with Net7, the classes are generated. There is zero output from the source generator.
The text was updated successfully, but these errors were encountered: