Error trying to sign in to CLI via `op signin`

imnotamember
imnotamember
Community Member

Attempting to setup the CLI as instructed here: https://developer.1password.com/docs/cli/get-started

I tried first via Homebrew, then with the standalone installer. Both led to the same error when attempting op signing:
panic: runtime error: index out of range [0] with length 0

Output of steps followed:

$ which op
/usr/local/bin/op
$ op --version
2.13.1

Now when I proceed to the instructions under "Sign in" on the doc. page:
- Step 1: I'm able to do Step 1. Settings > Developer > Enable "Connect with 1Password CLI"
- Step 2: I can't do anything for Step 2. Turn on Touch ID as I have an older Macbook Air without biometrics.
- I assumed this was okay to skip since going through the directions resulted in a screen with no options for TouchID:

Settings > Security > Select "Touch ID"

  • Step 3: I proceed to Step 3: Sign in to your account and have the following results:
$ op signin
panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/elastic/go-sysinfo/providers/darwin.kern_procargs(0xc0003ca270?, 0xc0000a7c20)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/elastic/go-sysinfo/providers/darwin/process_darwin.go:207 +0x58f
github.com/elastic/go-sysinfo/providers/darwin.(*process).Info(0xc0000a7c20)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/elastic/go-sysinfo/providers/darwin/process_darwin.go:104 +0x1b4
go.1password.io/op/core/procinfo.process.Executable(...)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/process_darwin.go:37
go.1password.io/op/core/procinfo.findNearestChildProcessInfo({0x100bef050?, 0xc00033ba30?}, 0x80b1)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/session_info.go:47 +0x48
go.1password.io/op/core/procinfo.getSessionInfo()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/session_info_unix.go:29 +0x12f
go.1password.io/op/core/procinfo.CurrentSessionInfo(...)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/session_info.go:21
go.1password.io/op/op-cli/desktopapp/ipc.clientInfo()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/ipc/ipc_darwin.go:77 +0x1e
go.1password.io/op/op-cli/desktopapp/ipc.Connect({0x100bee7c8, 0xc0003c9380}, {{0x100bec218, 0xc00033b4f0}, 0x7, {0x0, 0x0}, {0xc0002e0c00, 0x1, 0x1f4}, ...})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/ipc/connection.go:61 +0xa5
go.1password.io/op/op-cli/desktopapp.connect({0x100bee790?, 0xc00011c010?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/desktopapp.go:328 +0x9a
go.1password.io/op/op-cli/desktopapp.ListAccounts()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/desktopapp.go:93 +0x3e
go.1password.io/op/op-cli/command.filterSystemAuthAccounts({0x0, 0x0}, {0x0, 0x0})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:285 +0x4e
go.1password.io/op/op-cli/command.selectSystemAuthAccount({0x100bf3470, 0x1012428f0}, {0x0, 0x0}, {0x0?, 0x1b?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:326 +0x85
go.1password.io/op/op-cli/command.SignInWithSystemAuth({0x100bf3470, 0x1012428f0}, {0x0?, 0x60?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:205 +0x85
go.1password.io/op/op-cli/command.(*signinCommand).Run(0xc00034c060)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:144 +0x534
go.1password.io/op/op-cli/command.Bind.func3(0xc00030e840?, {0x1012428f0?, 0x0?, 0x0?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/command.go:71 +0x4e
github.com/spf13/cobra.(*Command).execute(0xc00030e840, {0x1012428f0, 0x0, 0x0})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/spf13/cobra/command.go:844 +0x67c
github.com/spf13/cobra.(*Command).ExecuteC(0x101204c80)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/spf13/cobra/command.go:952 +0x39d
go.1password.io/op/op-cli/command.Execute()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/root.go:327 +0x71
main.main()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/main.go:15 +0x31

I saw this in the logs an issue regarding my biometric authentication services:

INFO  XXXXXXXXXXXXX tokio-runtime-worker(ThreadId(342)) [1P:foundation/op-apple/src/biometry_service.rs:286] System biometry info: BiometricStatus { current_policy: BiometricsOnly, current_method: NoneAvailable, current_availability: NotAvailable }

I wasn't sure if potentially the fallback to user credentials was not setup or not in place for older Mac's without biometrics? Whatever the case, how can I get CLI working? I've tried the CLI manually add account approach with identical error as above:

op account add --address <my_address_omitted> --email <my_email_omitted> --secret-key <my_secret_key_omitted>
1Password CLI is now connected with the 1Password app. Add an account through the 1Password app.

To learn how to add an account to the 1Password app, visit: https://support.1password.com/add-account
$ eval $(op signin)
panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/elastic/go-sysinfo/providers/darwin.kern_procargs(0xc000115ba0?, 0xc000091c20)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/elastic/go-sysinfo/providers/darwin/process_darwin.go:207 +0x58f
github.com/elastic/go-sysinfo/providers/darwin.(*process).Info(0xc000091c20)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/elastic/go-sysinfo/providers/darwin/process_darwin.go:104 +0x1b4
go.1password.io/op/core/procinfo.process.Executable(...)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/process_darwin.go:37
go.1password.io/op/core/procinfo.findNearestChildProcessInfo({0x100bef050?, 0xc000359ab0?}, 0x80b1)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/session_info.go:47 +0x48
go.1password.io/op/core/procinfo.getSessionInfo()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/session_info_unix.go:29 +0x12f
go.1password.io/op/core/procinfo.CurrentSessionInfo(...)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/core/procinfo/session_info.go:21
go.1password.io/op/op-cli/desktopapp/ipc.clientInfo()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/ipc/ipc_darwin.go:77 +0x1e
go.1password.io/op/op-cli/desktopapp/ipc.Connect({0x100bee7c8, 0xc0003b4fc0}, {{0x100bec218, 0xc000359470}, 0x7, {0x0, 0x0}, {0xc0002f6c00, 0x1, 0x1f4}, ...})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/ipc/connection.go:61 +0xa5
go.1password.io/op/op-cli/desktopapp.connect({0x100bee790?, 0xc00018e010?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/desktopapp.go:328 +0x9a
go.1password.io/op/op-cli/desktopapp.ListAccounts()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/desktopapp/desktopapp.go:93 +0x3e
go.1password.io/op/op-cli/command.filterSystemAuthAccounts({0x0, 0x0}, {0x0, 0x0})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:285 +0x4e
go.1password.io/op/op-cli/command.selectSystemAuthAccount({0x100bf3470, 0x1012428f0}, {0x0, 0x0}, {0x0?, 0x1b?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:326 +0x85
go.1password.io/op/op-cli/command.SignInWithSystemAuth({0x100bf3470, 0x1012428f0}, {0x0?, 0x60?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:205 +0x85
go.1password.io/op/op-cli/command.(*signinCommand).Run(0xc000343ef0)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/signin.go:144 +0x534
go.1password.io/op/op-cli/command.Bind.func3(0xc00031cb00?, {0x1012428f0?, 0x0?, 0x0?})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/command.go:71 +0x4e
github.com/spf13/cobra.(*Command).execute(0xc00031cb00, {0x1012428f0, 0x0, 0x0})
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/spf13/cobra/command.go:844 +0x67c
github.com/spf13/cobra.(*Command).ExecuteC(0x101204c80)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/spf13/cobra/command.go:952 +0x39d
go.1password.io/op/op-cli/command.Execute()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/command/root.go:327 +0x71
main.main()
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/op-cli/main.go:15 +0x31

1Password Version: 1Password for Mac 8.9.13 (80913040)
Extension Version: Not Provided
OS Version: macOS 10.15.7
Browser:_ Not Provided
Referrer: forum-search:signin

Comments

  • imnotamember
    imnotamember
    Community Member

    As an update, I uninstalled op version 2.13.1 and then installed (via standalone) op version 2.8.0 (under the notion any Mac Touchbar update led to this issue) and it works fine now. I hope there's a solution out there as I'd love to update to the latest stable release! Thank you for any help you can offer 1password community!

  • Hi @imnotamember:

    Thanks for letting us know about this! I notice that you're using macOS 10.15.7. We're currently tracking an issue where version 2.13 or later of 1Password CLI has issues on macOS 10.15. If you try version 2.12, does that improve your state of play? Let me know. Additionally, if you're able to update your Mac to the latest version of macOS, that should also improve your state of play.

    Jack

    ref: dev/b5/op#3371

  • imnotamember
    imnotamember
    Community Member

    Thanks @Jack.P_1P ,

    Yup, I rolled back to 2.13.1 and that worked fine for me (not sure if you saw the update I posted just before your post). Do you still want me to roll back to 2.12 for debugging purposes?

  • ajs
    ajs
    Community Member

    Hi, In my case I did have to roll all the way back to v2.12 to get this working again. FWIW, I'm on a "MacBook Pro (Retina, 15-inch, Mid 2015)".

  • jga909
    jga909
    Community Member

    Hi !
    Same for me : iMac macOS 10.15.7 --> I had to downgrade to cli v2.12.0, if more recent it crashes :

    '''
    panic: runtime error: index out of range [0] with length 0
    goroutine 1 [running]:
    github.com/elastic/go-sysinfo/providers/darwin.kern_procargs(0xc0004c8098?, 0xc0004c40a0)
    /Users/iosdev/GitLab_CI_Builds/QNhFsVqy/0/dev/b5/op/vendor/github.com/elastic/go-sysinfo/providers/darwin/process_darwin.go:207 +0x58f
    '''

  • Hi @jga909:

    Thanks for following up. As I mentioned, version 2.12.0 should be fine.

    Jack

This discussion has been closed.