Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot use GitHub Copilot CLI extension in gh with 1Password #414

Open
blimmer opened this issue Dec 14, 2023 · 1 comment
Open

Cannot use GitHub Copilot CLI extension in gh with 1Password #414

blimmer opened this issue Dec 14, 2023 · 1 comment

Comments

@blimmer
Copy link

blimmer commented Dec 14, 2023

Platform or tool

GitHub

Desired or expected behavior

Copilot CLI is now a public beta and exposed through the gh CLI. However, it doesn't work when I'm using the op shell integration.

I followed the instructions to add the extension and enable it here: https://docs.github.com/en/copilot/github-copilot-in-the-cli/using-github-copilot-in-the-cli#installing-copilot-in-the-cli

Current behavior

I get an error that I'm not authed everytime I try to run a copilot command. If I unalias the 1password integration (unalias gh), and go through the normal logic process it works.

Relevant log output

> gh auth status
github.com
  ✓ Logged in to github.com account blimmer (GITHUB_TOKEN)
  - Active account: true
  - Git operations protocol: ssh
  - Token: ghp_************************************
  - Token scopes: 'copilot', 'gist', 'notifications', 'project', 'read:org', 'repo', 'user'
> gh copilot suggest hello

✗ Error: No valid OAuth token detected

To get started with GitHub Copilot in the CLI, please run: gh auth login --web -h github.com to authenticate via web browser.


If I go through the `gh auth login --web -h github.com` process, it succeeds, but I keep getting the "No valid OAuth token detected" error.

op CLI version

2.13.1

@DandyLyons
Copy link

DandyLyons commented Mar 22, 2024

This appears to still be an issue with gh copilot cli in the public release as well now.

op CLI version: 2.26.1
gh version: 2.46.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants