Repository navigation
fix(antigravity): stop sibling discovery after revocation #8024
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
Merged
lidge-jun
merged 12 commits into
lidge-jun:dev
from
luvs01:codex/fix-stale-oauth-token-leakage-issue
Nov 3, 2026
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
6bcf4d7
fix(antigravity): stop sibling discovery after revocation
luvs01 bdfd614
Merge commit 'c34d26ff2bde9516517fe7fd58c2bcda70ca5e03' into HEAD
luvs01 f739613
test(antigravity): revoke discovery authority before bearer send
luvs01 b0c048e
fix(antigravity): recheck discovery authority after refresh lock
luvs01 fff8e00
fix(oauth): recover independent callers after discovery cancellation
luvs01 fa5351b
Merge remote-tracking branch 'origin/dev' into lane/pr-8024
lidge-jun 024c236
refactor(oauth): move OAuth error classes into oauth-errors module
lidge-jun e502956
fix(antigravity): stop sibling discovery when the active account lose…
lidge-jun 109a712
fix(oauth): recheck needsReauth under the refresh lock for usable-acc…
lidge-jun f9f9f26
fix(oauth): keep a needsReauth mark set during an in-flight refresh
lidge-jun 08c39c7
Merge remote-tracking branch 'origin/dev' into lane/pr-8024d
lidge-jun 2751b2e
Merge remote-tracking branch 'origin/dev' into lane/pr-8024d
lidge-jun File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,67 @@ | ||
| import { errorDestinationText, providerErrorDestinationLabel } from "../lib/error-destination"; | ||
|
|
||
| export class UnsupportedOAuthProviderError extends Error { | ||
| constructor(provider: string) { | ||
| super(`Unsupported OAuth provider in config: ${errorDestinationText(providerErrorDestinationLabel(provider))}`); | ||
| this.name = "UnsupportedOAuthProviderError"; | ||
| } | ||
| } | ||
|
|
||
| export class OAuthLoginRequiredError extends Error { | ||
| readonly provider: string; | ||
|
|
||
| constructor(provider: string) { | ||
| super(`Not logged in to ${errorDestinationText(providerErrorDestinationLabel(provider))}. Run: ocx login ${errorDestinationText(providerErrorDestinationLabel(provider))}`); | ||
| this.name = "OAuthLoginRequiredError"; | ||
| this.provider = provider; | ||
| } | ||
| } | ||
|
|
||
| /** A usable-account caller found needsReauth under the refresh lock; unrestricted joiners retry alone. */ | ||
| export class OAuthAccountUnusableError extends OAuthLoginRequiredError {} | ||
|
|
||
| /** An operator-paused account is temporarily unavailable, not an invalid login. */ | ||
| export class OAuthAccountPausedError extends Error { | ||
| constructor() { | ||
| super("OAuth account is paused. Resume it in account settings and retry."); | ||
| this.name = "OAuthAccountPausedError"; | ||
| } | ||
| } | ||
|
|
||
| export class OAuthProviderPublicationError extends Error { | ||
| constructor(provider?: string, credentialWritten = true) { | ||
| super(provider !== "anthropic2" ? "OAuth credential was saved, but the provider entry was not written. Resolve the account namespace collision, then retry login." | ||
| : credentialWritten ? "Anthropic Pool 2 credential was saved as an orphan auth row, but the provider entry was not written. Repair the persisted config or resolve the provider/account namespace collision, then retry login." | ||
| : "Anthropic Pool 2 login did not start because the config file is missing or could not be written; no credential was saved. Repair the persisted config, then retry login."); | ||
| this.name = "OAuthProviderPublicationError"; | ||
| } | ||
| } | ||
|
|
||
| /** A local configuration conflict found before any credential is written; its text is fixed. */ | ||
| export class OAuthProviderNamespaceCollisionError extends Error { | ||
| constructor(message: string) { | ||
| super(message); | ||
| this.name = "OAuthProviderNamespaceCollisionError"; | ||
| } | ||
| } | ||
|
|
||
| export class OAuthReauthIdentityMismatchError extends Error { | ||
| constructor() { | ||
| super("Signed-in account does not match the selected account. Sign in with the same account."); | ||
| this.name = "OAuthReauthIdentityMismatchError"; | ||
| } | ||
| } | ||
|
|
||
| export class OAuthReauthIdentityUnverifiedError extends Error { | ||
| constructor() { | ||
| super("Could not verify signed-in account identity for reauth."); | ||
| this.name = "OAuthReauthIdentityUnverifiedError"; | ||
| } | ||
| } | ||
|
|
||
| export class OAuthLoginSupersededError extends Error { | ||
| constructor() { | ||
| super("OAuth login was superseded before credential persistence"); | ||
| this.name = "OAuthLoginSupersededError"; | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.