Update golang.org deps and Go version (#5595)

* Update golang.org deps and Go version

* Upgrade golangci-lint

* all: fix new vet warnings

https://github.com/golang/go/issues/60529 introduced a new
vet warning for when format strings are used without arguments,
which is technically a bug since it shouldn't be using the functions
taking format string arguments in those cases.
This commit is contained in:
Johan Brandhorst-Satzkorn authored and GitHub committed 2025-03-17 09:45:22 -07:00
1 parent 1fb52206e2
commit 3a49c8c483
33 files changed
+176 -174

No files matched your search

@@ -77,11 +77,14 @@ func ApiErrorWithCode(c codes.Code) error {
// ApiErrorWithCodeAndMessage returns an api error with the provided code and message.
func ApiErrorWithCodeAndMessage(c codes.Code, msg string, args ...any) error {
if len(args) > 0 {
msg = fmt.Sprintf(msg, args...)
}
return &ApiError{
Status: int32(runtime.HTTPStatusFromCode(c)),
Inner: &pb.Error{
Kind: c.String(),
Message: fmt.Sprintf(msg, args...),
Message: msg,
},
}
}