Merged
Conversation
Contributor
Author
|
The fwaas jobs are broken and I'm fixing them with #3631. |
stephenfin
approved these changes
Feb 12, 2026
Contributor
stephenfin
left a comment
There was a problem hiding this comment.
There's a lot here but it's all pretty trivial linter-related stuff, with the only meaningful thing being the actual go bump (the $subject of the whole PR). This lgtm
Contributor
|
#3632 is merged. Can you rebase this? |
Bump to to a supported version.
Done by bumping the version in the Makefile and running the
'golangci-lint migrate' command via podman as we do in the Makefile.
podman run -t --rm -v $PWD:/app -w /app \
golangci/golangci-lint:v2.1.6 \
golangci-lint migrate
This yields a number of news error from staticcheck, listed below, which
we temporarily ignore pending a fix.
S1038: should use fmt.Fprintf instead of fmt.Fprint(fmt.Sprintf(...))
ST1005: error strings should not be capitalized
ST1005: error strings should not end with punctuation or newlines
ST1017: don't use Yoda conditions
ST1019: package ".*" is being imported more than once
ST1019(related information): other import of ".*"
ST1023: should omit type .* from declaration; it will be inferred from the right-hand side
QF1011: could omit type .* from declaration; it will be inferred from the right-hand side
QF1001: could apply De Morgan's law
QF1003: could use tagged switch on .*
QF1004: could use strings.ReplaceAll instead
QF1008: could remove embedded field ".*" from selector
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
This looks complicated, but it's just a whole lot of sed invocations. Signed-off-by: Stephen Finucane <stephenfin@redhat.com> Conflicts: openstack/baremetal/v1/portgroups/results.go openstack/messaging/v2/messages/results.go openstack/messaging/v2/queues/results.go
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
More sed, along with some manual fixups.
sed -i 's/fmt.Errorf("\([A-Z]\)/fmt.Errorf("\L\1/' \
$(ag 'fmt.Errorf\("[A-Z]' -l)
sed -i 's/fmt.Errorf("\(.*\)\.")/fmt.Errorf("\1")/' \
$(ag 'fmt.Errorf\(' -l)
sed -i 's/errors.New("\([A-Z]\)/errors.New("\L\1/' \
$(ag 'errors.New\("[A-Z]' -l)
sed -i 's/errors.New("\(.*\)\.")/errors.New("\1")/' \
$(ag 'errors.New\(' -l)
(yes, that could have a one-liner but $complexity)
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
I'm not sure why this was disabled, but undisable it. Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
stephenfin
approved these changes
Feb 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Bump go to a supported version.
This forces us to upgrade golangci-lint as well. We essentially backport #3385 and #3519.