Skip to main content
neilio
June 27, 2023
Question

Can't sigin with CLI - "context deadline exceeded"

  • June 27, 2023
  • 9 replies
  • 1355 views

Not sure what's awry here, but I cannot log into my account via the CLI - I keep getting the error "context deadline exceeded". I have the same setup on another machine and it works there. Any ideas of how to fix this?


1Password Version: 2.19.0-beta.01
Extension Version: Not Provided
OS Version: macOS 14
Browser:_ n/a

9 replies

1Password Employee
June 28, 2023

Hi! I think the first step would be to run the problematic command with --debug enabled and copy paste the output in here. This could give us a bit more to work with for finding the issue. All the best, Andi.

neilio
neilioAuthor
June 28, 2023

↪ op signin --debug
11:03AM | DEBUG | Session delegation enabled
11:03AM | DEBUG | NM request: NmRequestAccounts
11:03AM | DEBUG | NM response: Success
11:03AM | DEBUG | NM request: NmRequestAccounts
11:03AM | DEBUG | NM response: Success
11:03AM | DEBUG | NM request: NmRequestAuthorization
11:03AM | DEBUG | NM response: Success
11:03AM | DEBUG | NM request: NmRequestAccounts
[ERROR] 2023/06/28 11:03:19 read: context deadline exceeded

July 4, 2023

I'm having the same issue, but I noticed that the behaviour is different depending on whether I've opened and unlocked 1password separately and left it open.

When i run op signin --debug --account <account> without doing so, I get the same as @neilio:

11:14AM | DEBUG | Session delegation enabled
11:14AM | DEBUG | NM request: NmRequestAccounts
11:14AM | DEBUG | NM response: Success
11:14AM | DEBUG | NM request: NmRequestAccounts
11:14AM | DEBUG | NM response: Success
11:14AM | DEBUG | NM request: NmRequestAuthorization
11:14AM | DEBUG | NM response: Success
11:14AM | DEBUG | NM request: NmRequestAccounts
[ERROR] 2023/07/04 11:14:53 read: context deadline exceeded

when I open and unlock 1password and run op signin --debug --account <account>:

11:09AM | DEBUG | Session delegation enabled
11:09AM | DEBUG | NM request: NmRequestAccounts
11:09AM | DEBUG | NM response: Success
11:09AM | DEBUG | NM request: NmRequestAccounts
11:09AM | DEBUG | NM response: Success
11:09AM | DEBUG | NM request: NmRequestAuthorization
11:09AM | DEBUG | NM response: Success
11:09AM | DEBUG | NM request: NmRequestAccounts
11:09AM | DEBUG | NM response: Success
11:09AM | DEBUG | NM request: NmRequestDelegatedSession
11:09AM | DEBUG | NM response: Success

the auth popup is at the NmRequestAuthorization step in both cases - but it seems like the application is closing too quickly or something in the case when it's being opened specifically by the CLI.

1Password Employee
July 14, 2023

I'm having the same issue, but I noticed that the behaviour is different depending on whether I've opened and unlocked 1password separately and left it open.

@celeriaccloaked @neilio
This is interesting information which makes me suspect the cause. What if you try CLI 2.18.0. I suspect this issue would not be happening with that previous version.

neilio
neilioAuthor
July 14, 2023

Thanks for your reply – I downgraded and at first I still had problems (I got the error "[ERROR] 2023/07/14 10:17:48 RequestDelegatedSession: native messaging: LostConnectionToApp" when I tried to log in via CLI). I worked around this by pre-launching the 1P app and then the CLI sign in worked.

1Password Employee
July 24, 2023

Thanks for your answer! So it is confirmed that the error ([ERROR] 2023/07/04 11:14:53 read: context deadline exceeded) is reproducible on 2.19.0 but not on 2.18.0. I was now able to reproduce and find the root cause for the issue. We are working on a fix internally.

All the best,
Andi

1Password Employee
July 28, 2023

Hey folks @neilio and @celeriaccloaked, could you also please share the 1Password 8 desktop app version you have installed, when this bug is appearing?

September 19, 2023

The bug is still there.
op 2.21.0
1 Password for Mac 8.10.15

This doesn't happen every time, and as the message mentions a timeout (I'm a Go developer, so I recognize the context.DeadlineExceeded error) I suspect this is related to the time the user takes to unlock the app.

Note that in my case the login succeed, but I got the error and a exit code 1.

neilio
neilioAuthor
September 19, 2023

FYI - currently using 1Password for Mac 8.10.18 (81018006).

The error is sporadic now, but still there – previously every time I tried to sign in I'd get the error.