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 in CI picks up golang v1.19 gofmt errors. #727

Closed
shahzadlone opened this issue Aug 5, 2022 · 1 comment · Fixed by #726
Closed

golangci-lint fails in CI picks up golang v1.19 gofmt errors. #727

shahzadlone opened this issue Aug 5, 2022 · 1 comment · Fixed by #726
Assignees
Labels
ci/build This is issue is about the build or CI system, and the administration of it.

Comments

@shahzadlone
Copy link
Member

Despite golangci-lint config having set to golang v1.18 for all linters and global options. The binary that golangci-lint has pre-built does not respect these config options (guess is probably because it was pre-compiled using go1.19). Everything works fine if we build it using go install from source though... however the golangci-lint action doesn't have a way to specify how to build it, but just takes the official pre-build binary.

So setting golangci-lint action to v1.47 should fix this for now.

@shahzadlone shahzadlone added the ci/build This is issue is about the build or CI system, and the administration of it. label Aug 5, 2022
@shahzadlone shahzadlone added this to the DefraDB v0.3.1 milestone Aug 5, 2022
@shahzadlone shahzadlone self-assigned this Aug 5, 2022
shahzadlone added a commit that referenced this issue Aug 5, 2022
- Resolves #727 

- Description: Since the release of golangci-lint `v1.48` the github action's pre-compiled version pick up GoLang v1.19 gofmt linter rules, despite explicitly setting v1.18. This PR would fix it to be `v1.47` for now.
@shahzadlone
Copy link
Member Author

Another similar fix:

golangci/golangci-lint-action#442 (comment)

shahzadlone added a commit to shahzadlone/defradb that referenced this issue Feb 23, 2024
- Resolves sourcenetwork#727 

- Description: Since the release of golangci-lint `v1.48` the github action's pre-compiled version pick up GoLang v1.19 gofmt linter rules, despite explicitly setting v1.18. This PR would fix it to be `v1.47` for now.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci/build This is issue is about the build or CI system, and the administration of it.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant