Skip to content

Commit

Permalink
A nicer error message in case someone forgets to run provider enroll (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
jhrozek authored Nov 6, 2023
1 parent e1a720e commit 8ed53dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/controlplane/handlers_repositories.go
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ func (s *Server) ListRemoteRepositoriesFromProvider(
_, owner_filter, err := s.getProviderAccessToken(ctx, provider.Name, projectID, true)

if err != nil {
return nil, status.Errorf(codes.PermissionDenied, "cannot get access token for provider")
return nil, util.UserVisibleError(codes.PermissionDenied, "cannot get access token for provider: did you run `minder provider enroll`?")

Check failure on line 433 in internal/controlplane/handlers_repositories.go

View workflow job for this annotation

GitHub Actions / golangci-lint / Go Lint

line is 138 characters (lll)
}

pbOpts := []providers.ProviderBuilderOption{
Expand Down

0 comments on commit 8ed53dc

Please sign in to comment.