When using a source generator via a <ProjectReference> inside a solution, and when the source generator needs to have dependencies, the solution documented by @sharwell here can be used. Unfortunately, while this still worked in 6.0.0-preview.7, it no longer seems to work in 6.0.0-rc.1.
For a minimal repro, see https://github.com/roji/Test/tree/SourceGeneratorRc1. Building that solution works in preview7, but in rc1 I'm getting the following:
CSC : warning CS8785: Generator 'NpgsqlConnectionStringBuilderSourceGenerator' failed to generate source. It will not contribute to the output and compilation errors may occur as a result. Exception was of type 'FileNotFoundException' with message 'Could not load file or assembly 'Scriban.Signed, Version=4.0.1.0, Culture=neutral, PublicKeyToken=5675fb69b15f2433'. The system cannot find the file specified. [/home/roji/projects/test/Test/Test.csproj]
When using a source generator via a
<ProjectReference>inside a solution, and when the source generator needs to have dependencies, the solution documented by @sharwell here can be used. Unfortunately, while this still worked in 6.0.0-preview.7, it no longer seems to work in 6.0.0-rc.1.For a minimal repro, see https://github.com/roji/Test/tree/SourceGeneratorRc1. Building that solution works in preview7, but in rc1 I'm getting the following: