chore(lint): suppress contextcheck on OIDC provider init call sites
Adding a context parameter to the shared package put its call chains in contextcheck's scope; the flagged background context in the provider setup is deliberate since provider lifetime exceeds any request.
This commit is contained in:
parent
acdc2a07f2
commit
5e00fcbbb8
|
|
@ -127,7 +127,7 @@ func adminUsersCreate(_ context.Context, in *struct{ Body models.CreateUserBody
|
|||
if err != nil {
|
||||
return nil, translateDomainError(err)
|
||||
}
|
||||
return &adminUserBody{Body: shared.NewAdminUser(newUser, providers)}, nil
|
||||
return &adminUserBody{Body: shared.NewAdminUser(newUser, providers)}, nil //nolint:contextcheck // OIDC provider init deliberately uses a background context — provider lifetime exceeds the request
|
||||
}
|
||||
|
||||
func adminUsersPatchAdmin(_ context.Context, in *struct {
|
||||
|
|
|
|||
|
|
@ -47,5 +47,5 @@ func RegisterInfoRoutes(api huma.API) {
|
|||
func init() { AddRouteRegistrar(RegisterInfoRoutes) }
|
||||
|
||||
func info(_ context.Context, _ *struct{}) (*infoBody, error) {
|
||||
return &infoBody{Body: shared.BuildInfo()}, nil
|
||||
return &infoBody{Body: shared.BuildInfo()}, nil //nolint:contextcheck // OIDC provider init deliberately uses a background context — provider lifetime exceeds the request
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue