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

Using go-version: 1.20 breaks the build #380

Closed
2 of 5 tasks
metalim opened this issue Jun 2, 2023 · 6 comments
Closed
2 of 5 tasks

Using go-version: 1.20 breaks the build #380

metalim opened this issue Jun 2, 2023 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@metalim
Copy link

metalim commented Jun 2, 2023

Description:
Using go-version: 1.20 breaks the build, as it uses Go 1.2 instead of 1.20

Action version:
v3 and v4

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:
1.20

Repro steps:

  • Create Go project with go.mod in it, with proper module name (in my case: github.com/metalim/gotest)
  • Add test file that imports that module
  • Confirm that go test ./... passes locally
  • Setup GH action with Go template
  • Change go-version for setup-go from 1.19 to 1.20
  • Observe build failing. Example: https://github.com/metalim/gotest/actions

Expected behavior:
Should use Go 1.20 or 1.20.4

Actual behavior:
Uses Go 1.2

@metalim metalim added bug Something isn't working needs triage labels Jun 2, 2023
@metalim
Copy link
Author

metalim commented Jun 2, 2023

As this was reported before, I suggest editing the Go template of GH action and using quoted version there, so it does not make confusion again. Just closing the issue as "dupe" is not productive action

@marko-zivic-93
Copy link
Contributor

Hello @metalim
Thank you for the heads up! We will investigate this issue and come back to you as soon as we have some results. 🙂

@nfuden
Copy link

nfuden commented Jun 2, 2023

A workaround is to use the go-version-file option as 1.20 will work in that setup

@gaby
Copy link

gaby commented Jun 9, 2023

Fixed via #382

@dmitry-shibanov
Copy link
Contributor

Hello everyone. I'm going to close the pull request because we added a note in scope of this pull request: #382

@metalim
Copy link
Author

metalim commented Jun 9, 2023

That might not help, and close was too early.
The cause of this issue originates from template provided by github, when you select template for Go Action:
image

image

README is not available at that point, but value already has incorrect format.
Requesting re-open

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants