We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4f69847 commit 925b351Copy full SHA for 925b351
internal/cli/auth/login.go
@@ -16,6 +16,7 @@ package auth
16
17
import (
18
"context"
19
+ "errors"
20
"fmt"
21
"os"
22
"time"
@@ -160,6 +161,10 @@ Your code will expire after %.0f minutes.
160
161
}
162
163
accessToken, _, err := opts.flow.PollToken(ctx, code)
164
+ var target *atlas.ErrorResponse
165
+ if errors.As(err, &target) && target.ErrorCode == "DEVICE_AUTHORIZATION_EXPIRED" {
166
+ return errors.New("authentication timed out")
167
+ }
168
if err != nil {
169
return err
170
0 commit comments