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

ci: Use go.mod for selecting the Go version #168

Merged
merged 1 commit into from
May 24, 2024
Merged

ci: Use go.mod for selecting the Go version #168

merged 1 commit into from
May 24, 2024

Conversation

nesv
Copy link
Contributor

@nesv nesv commented May 24, 2024

The "ci" workflow was previously using the "stable" and "oldstable" versions, which as of Go 1.22 introduces a slight change in how go.mod is formatted. This results in errors like

go: updates to go.mod needed; to update it:
	go mod tidy

in the workflow logs.

So instead of relying on mutable version labels like "stable" and "oldstable", this commit binds the version of Go used in CI to be what is specified in the repository's go.mod file.

This will allow us the ability to gradually update Go versions without needing to change the version in more than one place, and keep CI predictable.

General:

  • Have you removed all sensitive information, including but not limited to access keys and passwords?
  • Have you checked to ensure there aren't other open or closed Pull Requests for the same bug/feature/question?

Pull Request Guidelines:

  1. Does your submission pass tests?
  2. Have you added tests?
  3. Are you addressing a single feature in this PR?
  4. Are your commits atomic, addressing one change per commit?
  5. Are you following the conventions of the language?
  6. Have you saved your large formatting changes for a different PR, so we can focus on your work?
  7. Have you explained your rationale for why this feature is needed?
  8. Have you linked your PR to an open issue

The "ci" workflow was previously using the "stable" and "oldstable"
versions, which as of Go 1.22 introduces a slight change in how go.mod
is formatted. This results in errors like

	go: updates to go.mod needed; to update it:
		go mod tidy

in the workflow logs.

So instead of relying on mutable version labels like "stable" and
"oldstable", this commit binds the version of Go used in CI to be what
is specified in the repository's go.mod file.

This will allow us the ability to gradually update Go versions without
needing to change the version in more than one place, and keep CI
predictable.
@nesv nesv added the bug Something isn't working in this issue. label May 24, 2024
@nesv nesv self-assigned this May 24, 2024
@nesv nesv merged commit 55b73a9 into linode:main May 24, 2024
2 checks passed
@nesv nesv deleted the ci branch May 24, 2024 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working in this issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants