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

Set go 1.21.0, remove toolchain 1.22 statement #1217

Merged

Conversation

tesshuflower
Copy link
Contributor

Describe what this PR does

Explicitly sets go 1.21.0 in go.mod and removes the "toolchain" statement that got automatically put there by a go mod tidy.

We don't want to force a go 1.22 toolchain at this point. It looks like with go 1.21 it's encouraged to set an X.Y.Z version as you need an explicit release version for the toolchain stuff to work. In this case go mod tidy added the x.y.z and also added a toolchain statement with the go version used (I assume?) because we picked up syncthing which itself had a go.mod with go 1.21.0.

So simply using go 1.21.0 in our go.mod means we can now run go mod tidy and it won't add a "toolchain" directive to the file on us.

This is better explained here: golang/go#62278 (comment)

Is there anything that requires special attention?

Related issues:

Copy link
Contributor

openshift-ci bot commented Apr 17, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: tesshuflower

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@tesshuflower
Copy link
Contributor Author

/cc @JohnStrunk

@openshift-ci openshift-ci bot requested a review from JohnStrunk April 17, 2024 18:02
@JohnStrunk
Copy link
Member

/lgtm
I found this post to be useful: Forward Compatibility and Toolchain Management in Go 1.21 - The Go Programming Language

@openshift-ci openshift-ci bot added the lgtm label Apr 17, 2024
@openshift-merge-bot openshift-merge-bot bot merged commit 352b59d into backube:main Apr 17, 2024
27 checks passed
@tesshuflower tesshuflower deleted the go1.21-toolchain-update branch April 17, 2024 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants