-
Notifications
You must be signed in to change notification settings - Fork 80
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
Update supported go versions to 1.22+1.23 #659
Conversation
@@ -50,7 +50,6 @@ var expectedMetrics = []string{ | |||
"go_godebug_non_default_behavior_http2client_events_total", | |||
"go_godebug_non_default_behavior_http2server_events_total", | |||
"go_godebug_non_default_behavior_installgoroot_events_total", | |||
"go_godebug_non_default_behavior_jstmpllitinterp_events_total", |
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.
this seems to be no longer in go 1.23.
16fe0ae
to
2bed71d
Compare
@@ -19,7 +19,7 @@ type CallContainer struct { | |||
func (c *CallContainer) AddCall(call string, fail bool) error { | |||
c.Calls = append(c.Calls, call) | |||
if fail { | |||
return fmt.Errorf(call) | |||
return errors.New(call) |
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.
does go vet call this out now?
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.
staticcheck calls this out now: https://github.com/reddit/baseplate.go/actions/runs/10407002603/job/28821319767#step:6:7
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.
the main point I think is the dynamic string part, so a string literal would still work, and if you use something like fmt.Errorf("%s", call)
that likely also works.
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.
which I think makes sense, as there's a possibility call
contains some format verbs and then fmt.Errorf(call)
would cause an error.
No description provided.