-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
go1.21 support #3933
Comments
go1.21 has been released. But currently We have several solutions:
|
In terms of a quick fix and limited-effort band-aid it sounds as if
might be the best option right now as long a fixing the root cause is not possible? |
I also think this is the best move: #3922 (comment) |
gci needs to be upgraded by daixiang0/gci#163 to support the new packages |
go 1.21 adds a new
|
The
|
Collegue of @CubicrootXYZ here, yep this is correct, but there was no new release since then. So golangci-lint v1.53.3 was released on 15. June; the MR you refer to is from 09.July |
Yes, I explained that in the issue description: #3933 (comment) My previous answer was just facts related to the comment. |
I have an issue with $ go1.21.0 install github.com/golangci/golangci-lint/cmd/golangci-lint@master
$ golangci-lint run And this is the error message:
It was working fine before the upgrade. Please note that the |
can you provide a reproducible example? If you are facing a problem related to Go1.21, the best way to contribute is to open a new issue and provide the following information:
And a code example or link to a public repository. |
This comment was marked as off-topic.
This comment was marked as off-topic.
go1.21 is now officially fully supported since v1.54.1. Sponsoring is a good way to sustain open source maintainers: sponsor me |
For Go 1.21 support: golangci/golangci-lint#3933
For Go 1.21 support: golangci/golangci-lint#3933
* Bump golang from 1.20.7 to 1.21.0 Bumps golang from 1.20.7 to 1.21.0. --- updated-dependencies: - dependency-name: golang dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Update to `golangci@v1.54.1` For Go 1.21 support: golangci/golangci-lint#3933 --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: oliver-goetz <o.goetz@sap.com>
* Bump golang from 1.20.7 to 1.21.0 Bumps golang from 1.20.7 to 1.21.0. --- updated-dependencies: - dependency-name: golang dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Update to `golangci@v1.54.1` For Go 1.21 support: golangci/golangci-lint#3933 --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: oliver-goetz <o.goetz@sap.com>
* Bump golang from 1.20.7 to 1.21.0 Bumps golang from 1.20.7 to 1.21.0. --- updated-dependencies: - dependency-name: golang dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Update to `golangci@v1.54.1` For Go 1.21 support: golangci/golangci-lint#3933 --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: oliver-goetz <o.goetz@sap.com>
golangci-lint supports Go versions lower or equal to the Go version used to build it. More info: golangci/golangci-lint#3933
golangci-lint supports Go versions lower or equal to the Go version used to build it. More info: golangci/golangci-lint#3933
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Fixes the issues we observe with go 1.21. Reference: golangci/golangci-lint#3933 Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com>
Update tests.yml bumping golangci-lint Fixes the issues we observe with go 1.21. Reference: golangci/golangci-lint#3933 Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com>
* chore: fixes the CI status badge and updates the README.md file (#569) * Update README.md Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com> * Apply Joshua's feedback Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com> * Update README.md Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com> --------- Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com> * chore(deps): bump securesystemslib from 0.30.0 to 0.31.0 (#570) Bumps [securesystemslib](https://github.com/secure-systems-lab/securesystemslib) from 0.30.0 to 0.31.0. - [Release notes](https://github.com/secure-systems-lab/securesystemslib/releases) - [Changelog](https://github.com/secure-systems-lab/securesystemslib/blob/main/CHANGELOG.md) - [Commits](secure-systems-lab/securesystemslib@v0.30.0...v0.31.0) --- updated-dependencies: - dependency-name: securesystemslib dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs: add Marvin Drees to the list of go-tuf maintainers (#571) * chore(deps): bump actions/setup-python from 4.7.1 to 5.0.0 (#572) Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4.7.1 to 5.0.0. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](actions/setup-python@65d7f2d...0a5c615) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore: enable grouping of minor and patch updates. (#580) Enable grouping of minor and patch updates. Enable automerge. Signed-off-by: Fredrik Skogman <kommendorkapten@github.com> * fix: update tests.yml bumping golangci-lint (#582) Update tests.yml bumping golangci-lint Fixes the issues we observe with go 1.21. Reference: golangci/golangci-lint#3933 Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com> * chore(deps): bump actions/setup-go from 4.1.0 to 5.0.0 (#573) Bumps [actions/setup-go](https://github.com/actions/setup-go) from 4.1.0 to 5.0.0. - [Release notes](https://github.com/actions/setup-go/releases) - [Commits](actions/setup-go@93397be...0c52d54) --- updated-dependencies: - dependency-name: actions/setup-go dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Radoslav Dimitrov <radoslav@stacklok.com> * chore(deps): bump github/codeql-action from 2 to 3 (#574) Bumps [github/codeql-action](https://github.com/github/codeql-action) from 2 to 3. - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](github/codeql-action@v2...v3) --- updated-dependencies: - dependency-name: github/codeql-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Radoslav Dimitrov <radoslav@stacklok.com> * chore(deps): bump golang.org/x/crypto from 0.16.0 to 0.17.0 (#575) Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.16.0 to 0.17.0. - [Commits](golang/crypto@v0.16.0...v0.17.0) --- updated-dependencies: - dependency-name: golang.org/x/crypto dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Radoslav Dimitrov <radoslav@stacklok.com> * chore(deps): bump golang.org/x/term from 0.15.0 to 0.16.0 (#577) Bumps [golang.org/x/term](https://github.com/golang/term) from 0.15.0 to 0.16.0. - [Commits](golang/term@v0.15.0...v0.16.0) --- updated-dependencies: - dependency-name: golang.org/x/term dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(deps): bump the minor-patch group with 2 updates (#581) Bumps the minor-patch group with 2 updates: [github.com/secure-systems-lab/go-securesystemslib](https://github.com/secure-systems-lab/go-securesystemslib) and [golang.org/x/crypto](https://github.com/golang/crypto). Updates `github.com/secure-systems-lab/go-securesystemslib` from 0.7.0 to 0.8.0 - [Release notes](https://github.com/secure-systems-lab/go-securesystemslib/releases) - [Commits](secure-systems-lab/go-securesystemslib@v0.7.0...v0.8.0) Updates `golang.org/x/crypto` from 0.17.0 to 0.18.0 - [Commits](golang/crypto@v0.17.0...v0.18.0) --- updated-dependencies: - dependency-name: github.com/secure-systems-lab/go-securesystemslib dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-patch - dependency-name: golang.org/x/crypto dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --------- Signed-off-by: Radoslav Dimitrov <radoslav@stacklok.com> Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: Fredrik Skogman <kommendorkapten@github.com> Co-authored-by: Radoslav Dimitrov <radoslav@stacklok.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Update
2023-08-11
go1.21 is now officially fully supported since v1.54.1.
2023-08-10
The problems with ruleguard/gocritic are fixed.
A new release will happen quickly.
2023-08-09
go1.21 is now officially supported since v1.54.0 but there are still problems:
ruleguard
(a "rule" insidego-critic
) doesn't work with go1.21. go1.21: load rules: parse rules file: typechecker error: ...: could not import quasilyte/go-ruleguard#449go-critic
fails to load its built-in/embedded rules. go1.21: load embedded ruleguard rules: rules/rules.go:13: can't load fmt go-critic/go-critic#1359Is golangci-lint support go1.21?
No, and yes.
Basically, golangci-lint supports Go versions lower or equal to the Go version used to build it.
The current binaries from the releases page and the Docker images have been built with go1.20 and will be built with go1.20 as long as go1.21 is not GA.
So those binaries/images don't support go1.21.
https://golangci-lint.run/usage/faq/#which-go-versions-are-supported
In addition, of the Go version used to build it, some linters could need to be updated to support newer versions of Go, and internal pieces of golangci-lint could also need to be updated.
You can follow the PR #3922 to see the progress on this topic.
Sponsoring is a good way to sustain open source maintainers: sponsor me
The text was updated successfully, but these errors were encountered: