golangci-lint run fails with: can't run linter goanalysis_metalinter: buildssa: failed to load package <package_name>: could not load export data: no export data for <package> #3363
Unanswered
tigrkoshka
asked this question in
Q&A
Replies: 2 comments
-
Same issue, and I get it while running the dockerize'd version : The package that is causing the problem was generated by protoc_gen_go 1.27.1 for me. |
Beta Was this translation helpful? Give feedback.
0 replies
-
For me it seems like issue with golangci-lint trying to fetch the private dependencies. Assuming there's |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have a rather big repository with all kind of different packages, some of which use CGO. I am trying to run golangci-lint on a directory that does not use CGO, but in one files depends on a package that does, which gives me
I have seen similar discussions, but none of the tips helped me.
I am assuming the problem is with CGO usage, because golangci-lint reports the code that dos not compile as pure Go.
How can I enable CGO in golangci-lint run or, alternatively, how can I tell golangci-lint to ignore that package?
If that requires ignoring my packages/files that depend on the CGO package -- that's fine, because there is only one such file. I have tried skip-dirs or skp-files in config, but that doesn't seem to work.
I have also run
go mod tidy
, but that didn't help either.golangci-lint version: 1.50.1
go version: 1.19
Beta Was this translation helpful? Give feedback.
All reactions