generated from albertocavalcante/cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
Problem
When running make lint, golangci-lint fails with version mismatch errors if the local Go installation version differs from the Bazel-managed Go version.
Current versions:
- Local Go: 1.24.1
- Bazel-managed Go: 1.23.7
This causes false positives in the linting process, even though the code is correct.
Current Workaround
Currently, we need to skip the lint step when we know it's a false positive due to the Go version mismatch.
Potential Solutions
-
Use
nogoanalyzer from rules_go (requires significant rework) -
Use
bazel-nogo-lint(experimental)- Reference: https://github.com/anuvu/bazel-nogo-lint
-
Configure golangci-lint to use Bazel's Go version (not directly supported yet)
Next Steps
- Research and evaluate the potential solutions
- Choose the most appropriate solution based on:
- Maintenance overhead
- Integration complexity
- Long-term sustainability
Related Rules
From our Go rules:
AVOID using the local
goinstallation on the host machine. PREFER to use the Bazel-managed Go SDK viarules_go.
Reactions are currently unavailable