Closed damif94 closed 1 year ago
@mgechev
Hi @damif94 thanks for the PR.
As you say, the case of false positives is sufficiently rare to keep the rule as is (moreover, setting the confidence to .95 will not have actual effects on the use of revive
on IDEs, the use case you described in the original issue)
I'll close the PR and, if there a real need (too much false positives) we can re-open it.
Thanks again.
Followup PR for https://github.com/mgechev/revive/issues/853
Interacting with the new rule
redundant-import-alias
on my company projects, it has turned out really useful. But in some rare occasions, the warning is not accurate. Indeed, when the package name does not match the folder name (I guess this is too rare in any go project).The proper solution is to actually check that the alias matches the package name, but meeting that requirement would trade-off performance and memory usage. So, I guess a more humble fix is to reduce de
Confidence
parameter inside the failure.