Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bn222 why do we need to require .4 explicitly ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gopls doesn't work with non-explicit z-stream. Also, our images downstream are 1.22.4. Making it explicit brings our env and upstream in alignment.
Side note: A difference between 1.22.1 and 1.22.4 causes code gen to behave differently. Making it explicit makes sure everyone is generating the same code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't like this approach. It will force us to. make more updates (1.22.5 is already releases). Could you please provide any real example how this will help?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, As far as I know. version specified in the go.mod file is the minum required version for this project to build.
https://go.dev/doc/modules/gomod-ref
So, there will be no need to bump this in the future in my opinion.
@bn222 do you have any reference (github issue, stackoverflow) to the problem with gopls?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NixOS/nixpkgs#293180
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's the closest I can find. On my system, after I've added
.4
, it started working.Note also that operator-sdk generates a bit different code depending on 1.22 vs 1.22.4, so if someone is on 1.22.4, and they run
make generate
, they will generate different code than someone who is running on 1.22. IMO, it's better to be explicit on which version everyone should be on.