Skip to content

upgrade version of Go in GitHub checks#637

Merged
josieang merged 4 commits intogoogle:mainfrom
josieang:upgrade-go
Nov 3, 2023
Merged

upgrade version of Go in GitHub checks#637
josieang merged 4 commits intogoogle:mainfrom
josieang:upgrade-go

Conversation

@josieang
Copy link
Copy Markdown
Collaborator

@josieang josieang commented Nov 3, 2023

I want to use errors.Join in the following PR:

It is a method added in go 1.20.

I want to use errors.Join in the following PR:
- License checker feature google#501

It is a method added in go 1.20.
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Nov 3, 2023

Codecov Report

Merging #637 (04ca816) into main (f08125b) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #637   +/-   ##
=======================================
  Coverage   78.82%   78.82%           
=======================================
  Files          78       78           
  Lines        5511     5511           
=======================================
  Hits         4344     4344           
  Misses        990      990           
  Partials      177      177           

@another-rex
Copy link
Copy Markdown
Collaborator

Can you also change the go version in the go.mod?

@G-Rath
Copy link
Copy Markdown
Collaborator

G-Rath commented Nov 3, 2023

Isn't this a breaking change though for the library?

@another-rex
Copy link
Copy Markdown
Collaborator

I was thinking about that, but it looks like go 1.19 is out of support anyway? https://endoflife.date/go

I'm actually not sure how libraries are suppose to bump versions if we have to do a major version change every go release.

@G-Rath
Copy link
Copy Markdown
Collaborator

G-Rath commented Nov 3, 2023

I thought it that libraries don't need to worry EOL because that only matters for the version of Go that is doing the compiling - i.e. osv-scanner (the cli) should be being built with an in-life version of Go, but osv-scanner (the library) can remain compatible with EOL version of Go

@josieang
Copy link
Copy Markdown
Collaborator Author

josieang commented Nov 3, 2023

I opt for upgrading the version of Go. And that this shouldn't require a major version bump.

  • Go is backwards compatible, upgrading is encouraged by the Go project. Upgrading should be a good thing and easy to do. I don't think it makes sense for osv-scanner to support people stuck at Go 1.19.
  • I don't think osv-scanner should only use old features of Go until a major version bump. This is much more like a minor change.

However, we might like to make a policy that osv-scanner will user versions of Go at least two release behind or something.
#638

Copy link
Copy Markdown
Collaborator

@another-rex another-rex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, we'll increase them minor version of osv-scanner when this releases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants