Skip to content

fix/login: validate keyring oauth creds and re-auth if needed#1331

Merged
burmudar merged 2 commits into
mainfrom
wb/login-reauth
Jun 2, 2026
Merged

fix/login: validate keyring oauth creds and re-auth if needed#1331
burmudar merged 2 commits into
mainfrom
wb/login-reauth

Conversation

@burmudar
Copy link
Copy Markdown
Contributor

@burmudar burmudar commented Jun 1, 2026

If we have loaded from the OAuth store and validation fails with the token, re-launch the OAUth flow

Closes PLAT-701

Test plan

  1. src login https://sourcegraph.test:3443
  2. revoke in UI
  3. src login https://sourcegraph.test:3443
./src2 login https://sourcegraph.test:3443
The OAuth token is invalid. Please check that the Sourcegraph CLI client is still authorized.

To re-authorize, run: src login https://sourcegraph.test:3443

Learn more at https://github.com/sourcegraph/src-cli#readme


⚠️  Warning: Stored OAuth credentials could not be verified. Starting a new OAuth device flow.

If your browser did not open automatically, visit https://sourcegraph.test:3443/auth/device?user_code=JNELRRVD.
Waiting for authorization... DONE


✔︎ Authenticated as sourcegraph on https://sourcegraph.test:3443


✔︎ Authenticated with OAuth credentials

@burmudar burmudar requested a review from jac June 1, 2026 15:37
@burmudar burmudar self-assigned this Jun 1, 2026
@burmudar burmudar requested a review from a team June 1, 2026 15:37
@burmudar burmudar merged commit 65e12ed into main Jun 2, 2026
8 checks passed
@burmudar burmudar deleted the wb/login-reauth branch June 2, 2026 15:29
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

Successfully merging this pull request may close these issues.

3 participants