Closed L00pZBreak3r closed 1 year ago
I had the same problem when I added the Microsoft.Windows.SDK.Win32Metadata
package (49.0.21-preview) to my project.
Removing it allowed the source generator to work again.
Not sure what the issue is.
Each major version update of metadata carries with it the potential to break the source generator. We need a source generator update to get you to the latest metadata, evidently.
Actual behavior
Generator 'SourceGenerator' failed to generate source. It will not contribute to the output and compilation errors may occur as a result. Exception was of type 'ArgumentException' with message 'An item with the same key has already been added.'
Expected behavior
Successful compilation.
Repro steps
NativeMethods.txt
content:NativeMethods.json
content (if present):Any of your own code that should be shared?
Context
LangVersion
(if explicitly set by project): [e.g.9
]