Skip to content
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

golangci-lint fails because it cannot find go in $PATH #464

Open
shackra opened this issue Jun 20, 2024 · 1 comment
Open

golangci-lint fails because it cannot find go in $PATH #464

shackra opened this issue Jun 20, 2024 · 1 comment
Labels
flake Related to running in pure environments

Comments

@shackra
Copy link

shackra commented Jun 20, 2024

This happens when running nix flake check.

golangci-lint............................................................Failed
- hook id: golangci-lint
- exit code: 3

WARN Failed to discover go env: failed to run 'go env -json GOCACHE GOROOT': exec: "go": executable file not found in $PATH
ERRO Running error: context loading failed: failed to load packages: failed to load packages: failed to load with go/packages: err: go command required, not found: exec: "go": executable file not found in $PATH: stderr:

This may be related to the fact that flakes do not admit environment variables. It goes well as a pre-commit-hook, thought.

@sandydoo sandydoo added the flake Related to running in pure environments label Jul 9, 2024
@shackra
Copy link
Author

shackra commented Oct 18, 2024

still failing :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flake Related to running in pure environments
Projects
None yet
Development

No branches or pull requests

2 participants