-
Notifications
You must be signed in to change notification settings - Fork 4
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
Switch to using analysis framework natively with fact export #5
Comments
Ah makes sense, I'll take a look. |
Thanks for taking a look. As far as in-memory caching goes, my recommendation is the following strategy:
Another thing to worry about with using the facts API: once you add analyzer facts, drivers will start running the analyzer against the dependency closure rather than just the packages in question. Sadly, this will drop performance of the singlechecker considerably. There's not really a workaround aside from adding some config option to exclude reporting and fact gathering on certain packages. |
What caching are you referring to? I've used the facts API before and looking at how it would be used here, it seems sufficient for this use case. |
It would be acceptable to use no in memory caching and purely rely on the facts API. |
As noted in golangci/golangci-lint#4158, this linter is incompatible with the analysis framework because it strongly relies on state across packages, and this state is not exported using the facts API.
The analyzer shim present in golangci-lint seems insufficient in dealing with this limitation. This entire module would likely need to be re-written as an analyzer.
The text was updated successfully, but these errors were encountered: