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

Local Linting Tool version mismatch #1241

Closed
barbacbd opened this issue May 21, 2024 · 0 comments · Fixed by #1242
Closed

Local Linting Tool version mismatch #1241

barbacbd opened this issue May 21, 2024 · 0 comments · Fixed by #1242
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@barbacbd
Copy link
Contributor

/kind bug

What steps did you take and what happened:
[A clear and concise description of what the bug is.]
run make lint

What did you expect to happen:
I expected the errors that were shown on an open pull request to be present on the screen.

Anything else you would like to add:
[Miscellaneous information that will assist in solving the issue.]
The linter that comes with the project appears to be v1.57.2. If we run this version we will see

Error: unknown linters: 'canonicalheader,fatcontext', run 'golangci-lint help linters' to see the list of supported linters
Failed executing command with error: unknown linters: 'canonicalheader,fatcontext', run 'golangci-lint help linters' to see the list of supported linters

These linters were added in golangci-lint v1.58.0 and v1.58.2. The version that comes in hack/tools/bin is 1.57.2 and the default version in the makefile points to 1.57.2. If I download 1.58.2 and move it to the bin and change the default version I am able to see the errors I expected.

Environment:

  • Cluster-api version:
  • Minikube/KIND version:
  • Kubernetes version: (use kubectl version):
WARNING: This version information is deprecated and will be replaced with the output from kubectl version --short.  Use --output=yaml|json to get the full version.
Client Version: version.Info{Major:"1", Minor:"27", GitVersion:"v1.27.4", GitCommit:"795bf1a6260847ecfc612da2ab11ea2d6e07da16", GitTreeState:"clean", BuildDate:"2023-09-19T03:35:46Z", GoVersion:"go1.20.5 X:strictfipsruntime", Compiler:"gc", Platform:"linux/amd64"}
Kustomize Version: v5.0.1
Server Version: version.Info{Major:"1", Minor:"28", GitVersion:"v1.28.9+416ecaf", GitCommit:"922efb2e165deb536505cab2f1d98a6a3146f766", GitTreeState:"clean", BuildDate:"2024-05-08T14:13:08Z", GoVersion:"go1.20.12 X:strictfipsruntime", Compiler:"gc", Platform:"linux/amd64"}
  • OS (e.g. from /etc/os-release): Fedora 38
@k8s-ci-robot k8s-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label May 21, 2024
@cpanato cpanato self-assigned this May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants