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
System.IO.FileNotFoundException #957
Comments
@sungam3r Thanks for opening this issue. I added a test for this analyzer package. It had no issue loading on its own, so the issue may be that multiple versions of the Gu.Roslyn.Extensions are being loaded and we are not isolating these dependencies (which is a bug filed under #734). I also noticed that the FixAllProviders were failing from this package and implemented a fix to support them. See #958. |
After updating the test to load more of the Analyzers from your project, the true issue was revealed. We resolve dependencies when the Analyzer and CodeFix types are realized. However, we were only tracking the last analyzer assembly paths as a search path. In this case the Gu.Roslyn.Extensions assembly isn't present in that final path causing the FileNotFoundException. |
Going to take this a step further and simply isolate each analyzer into its own assemblyloadcontext. |
I'm glad to hear that. |
How can I get a new version to try the fix? |
@sungam3r Typically we have a nightly build, but I kicked it off special for these fixes. You should be able to uninstall and reinstall the dotnet-format tool to get the latest version. |
Thank you. It works. |
See explanation in DotNetAnalyzers/IDisposableAnalyzers#259
How to deal with that error ?
The text was updated successfully, but these errors were encountered: