Skip to content

Scope Claude OAuth cache by profile - #2380

Open
ProspectOre wants to merge 14 commits into
steipete:mainfrom
ProspectOre:fix/claude-keychain-ownership
Open

Scope Claude OAuth cache by profile#2380
ProspectOre wants to merge 14 commits into
steipete:mainfrom
ProspectOre:fix/claude-keychain-ownership

Conversation

@ProspectOre

@ProspectOre ProspectOre commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Layer 2 of 5: profile/cache foundation and safe cache access

This replaces the former aggregate diff with the cache/migration layer requested in maintainer review.

Depends on #2441 (test isolation). Until #2441 lands, this branch contains its current-main rebased equivalent so the layer remains independently buildable and testable. The production review target is five commits on top: profile-scoped Claude OAuth cache state, the Keychain ACL safety gate found by exact packaged-app verification, serialized delegated-refresh attribution found by Codex review, the ambient-attribution/profile-corroboration correction, and the latest cross-profile prompt/preflight/failure-gate safety corrections.

Root cause and principles-first fix

The repeated password dialog was not controlled solely by the Claude prompt preference. CodexBar cache reads used a secret-data Keychain query, and an attributes-only preflight could report success even when the cache item's decrypt ACL did not trust the current packaged executable. The later secret query could therefore invoke macOS authorization UI despite the no-prompt setting.

The shared cache boundary now:

  • requests attributes plus item reference without requesting secret data;
  • inspects the item's decrypt ACL before every read, update, or delete;
  • permits access only when the decrypt ACL is non-interactive and trusts the current CodexBar app/CLI executable (or is explicitly unrestricted);
  • fails closed for unknown, foreign, or prompt-bearing ACLs so no later cache operation can display authorization UI;
  • preserves normal cache read/update/delete behavior for authorized items and lets the full stack fall back to the authenticated Claude owner CLI when a cache item is unsafe.

Codex review also identified two attribution hazards. First, the coordinator released profile A's in-flight slot before A synchronized Claude's global Keychain result, allowing profile B to replace that global item in the gap. File reconciliation and Keychain-to-profile-cache synchronization now execute inside the same serialized coordinator task, before the in-flight slot is released. Second, an ordinary profile-cache miss could copy Claude's global, profile-less Keychain item into any selected profile. Ordinary cache misses now fail closed; only the explicitly attributed serialized post-delegated-refresh path can seed a profile cache from that item.

Account corroboration and credential-file fingerprints now use the same selected fetch environment, including custom CLAUDE_CONFIG_DIR and HOME, so a default-home account cannot be mistaken for the selected profile.

The latest review found three remaining shared-state boundaries. Interactive prompt outcomes are now tagged with the selected profile and cannot be replayed into another profile in the same refresh request. Cache ACL preflight now authorizes only the executable that will actually perform the secret operation, so trust granted to the app cannot authorize the CLI (or vice versa). Refresh-failure fingerprints now observe only the selected profile's credentials file, so an unrelated change to Claude's global Keychain item cannot unblock another profile.

The follow-up review closed the final persistence gaps: an unsafe cache ACL is now a typed cache miss so it cannot suppress owner-mediated recovery; an interactive read of Claude's global, profile-less item remains ephemeral and is never persisted under a selected profile; and delegated refresh recovery now seeds the profile cache only from that selected profile's credentials file, never from a global item that another process could replace.

The final diagnostics review found one remaining profile-labeling error: the debug cooldown query used the process-default profile. It now receives the same selected fetch environment as the rest of the Claude diagnostic, with a regression proving a custom CLAUDE_CONFIG_DIR cannot display another profile's cooldown.

Profile and upgrade behavior

  • scopes cache keys, invalidation, credential-file tracking, refresh-failure gates, delegated refresh in-flight work/cooldown, and pending cleanup to the active Claude credentials profile;
  • derives profile identity from CLAUDE_CONFIG_DIR, CLAUDE_SECURESTORAGE_CONFIG_DIR, and HOME;
  • migrates eligible historical default-profile entries without allowing ambiguous or cross-profile reuse;
  • persists profile-owned cleanup tombstones, including a durable legacyRecheckPending state when the legacy lookup is temporarily unavailable;
  • prevents stale legacy credentials from being re-imported after logout or invalid_grant;
  • preserves the owning profile when a pending-cache lock is unavailable;
  • scopes coalesced interactive prompt outcomes to the selected profile;
  • keeps refresh-failure recovery tied to the selected profile rather than Claude's global Keychain item;
  • restricts Keychain-to-cache synchronization to the explicitly attributed, serialized post-delegated-refresh path;
  • preserves a persisted .never policy for foreign Claude Keychain reads while allowing CodexBar-owned cache use.

Regression coverage

The tests cover:

  • overlapping delegated refreshes for two profiles while Claude's global Keychain item changes A → B, proving cache A → A and cache B → B;
  • ordinary cache misses under every prompt policy, proving a global Claude item is never assigned to an arbitrary profile;
  • selected-account corroboration across two custom CLAUDE_CONFIG_DIR profiles and a custom HOME;
  • no shared delegated-refresh results or cooldown between profiles;
  • no cross-profile reuse of a concurrent interactive prompt outcome;
  • no profile refresh unblock when only Claude's global Keychain item changes;
  • temporarily unavailable legacy lookup followed by recovery without stale credential resurrection;
  • forced legacy deletion failure and durable invalidation;
  • sibling-profile preservation and cache-only/file-backed profile switching;
  • released pathless credential-file fingerprint migration;
  • authorized, unrestricted, prompt-bearing, foreign, and unknown decrypt ACLs;
  • invoking-executable-only ACL preflight, proving one first-party executable cannot authorize another;
  • no secret-data query before ACL authorization;
  • read, update, delete, and duplicate-add race behavior under the same gate.

Scope boundary

This PR intentionally does not contain the owner-CLI shutdown/routing changes, UI/recovery copy, or live verifier. Those remain prepared as layers 3–5 so each concern is independently reviewable. The forward-integration candidate below proves the complete user-visible path.

Verification

Exact PR head b60fa59b6efcd9323f2efccbf750432e65ef0bd6:

  • make check: passed; SwiftFormat 0/1,598 and SwiftLint 0/1,597;
  • canonical make test: 734/734 selections in 62/62 groups, zero failures, retries, or timeouts;
  • focused cooldown/account-isolation matrix: 25 tests across 3 suites passed;
  • git diff --check: passed;
  • refreshed GitHub CI is running on this exact head.

Forward-integration candidate 143dfed7aba3f548093ceb46285ec9afcaedccbf (layers 1–5):

  • make check: passed; SwiftFormat 0/1,598 and SwiftLint 0/1,597;
  • canonical make test: 734/734 selections in 62/62 groups, zero failures, retries, or timeouts;
  • ownership verifier: 237 tests across 22 suites plus 3 explicitly consent-gated live tests passed;
  • fresh packaged Release fetch: authenticated Claude owner path, exit 0, provider=claude, source=claude, structured usage payload present;
  • four first-party Release executables audited, zero Security descendants, zero unowned Security descendants, zero foreign-reader markers;
  • unified-log canary observed, 18 attributed owner-Keychain events, zero attributable prompt/authorization events;
  • verifier source snapshot SHA-256: c430b636011683c8ebc02f621da7ea1cbbd173f58f67747d1127a3924e740f2f;
  • packaged CLI SHA-256: ce2695823cbb1c624ac6592265f219cb6b71e4de80d48ce6184cc8ef2cc32c1b;
  • packaged app SHA-256: af36af80f2cab4e520658bdce60b8e9a0297f8c35c8bbe1a0d294bcf5db74f94.
    The bounded live run completed July 28, 2026 at 12:14 PM PDT. The proof contains hashes, counts, and route status only—no account identity, credential/token values, usage values, customer data, or raw logs. The local package is ad-hoc signed because this machine has no Developer ID Application identity; a maintainer-signed artifact remains the release-signing gate.

Copy link
Copy Markdown
Contributor Author

Redacted live credential-ownership proof

Exact PR head: 2ed4b72854b7a9a47aaa3e17d7e211ff04d368c7
Executed: 2026-07-21T17:12:12-07:00 (PDT)
Environment: macOS 27.0 (arm64), CodexBar 0.45.2, Claude Code 2.1.217

This proof intentionally excludes account identity, credentials, token values, usage amounts, raw Keychain records, raw CLI payloads, raw unified-log lines, and private filesystem paths. The private verifier directory was not uploaded.

Before / root cause

Redacted historical live logs showed Claude replace its owned credential item and CodexBar prompt again 15 seconds later. That proves a user ACL grant was temporary: Claude's next credential refresh replaced the item CodexBar was reading.

Exact-head results

  • exact source snapshot SHA-256: cb453453c80fa443b169c89d2b67f5c9b9e0e665153a129667426d4e6aa892e8
  • source snapshots before/after packaging identical: yes
  • Release built by verifier: yes
  • first-party Release executables audited: 4
  • known foreign-reader markers: 0
  • focused ownership/routing/account tests: 72 tests / 11 suites passed
  • live owner-path tests: 2 tests / 1 suite passed
  • owner authentication preflight: success
  • live provider/source: claude / claude
  • live usage payload shape: dictionary (values redacted)
  • CLI exit: 0
  • timeout: no
  • Security descendants: 0
  • unowned Security descendants: 0
  • unified-log visibility canary: observed
  • attributable prompt/authorization events: 0

Release executable hashes

  • Contents/MacOS/CodexBar: 41d3fb4025ce8891d427c7ba226d9be9da7d941e44ee1029c166cea7e9a1094f
  • Contents/Helpers/CodexBarClaudeWatchdog: d0ec8984832ff02a4db89416fa0de6a4e2d813c1a6681e920bcaf5fb6b39a56b
  • Contents/Helpers/CodexBarCLI: d9f50d8329613d63295ed5a90ecd8e0f1b024c585eb38e7090acc5f22f369f63
  • Contents/PlugIns/CodexBarWidget.appex/Contents/MacOS/CodexBarWidget: f05d994751ccd6e8f5ca9eb23f50faa1a8cbbc5f642b94e6b6a566664b2bab44

The manifest was rechecked against the packaged app after the run; all four hashes passed.

Broader validation

  • full local suite: 728 selected cases across 61 groups, zero failures/retries/timeouts
  • SwiftFormat: 0/1591 files need changes
  • SwiftLint strict: 0 violations across 1590 files
  • documentation links, locales, shell syntax/static analysis, and diff checks pass
  • known unrelated environment caveat: stock make check encounters the repository's existing Node 25 docs/site.js ESM-mode mismatch; equivalent module-mode validation passes

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 22, 2026

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

Re-review progress:

@ProspectOre

Copy link
Copy Markdown
Contributor Author

Exact-head redacted live proof — 2026-07-21 22:27 PDT

Candidate: 3d0dc5e09f71df5887c446fb79e1412f0bea41da

Build integrity:

  • verifier packaged a fresh Release bundle from a clean candidate worktree
  • source snapshot SHA-256: 4f2ae006aff2748ebf6311b4699ed1bd6b090fd7668310819612a7c9e2b6a716
  • 4 first-party Release executables audited
  • known foreign-reader markers: 0

Logged-in Claude owner-path result:

  • Claude owner authenticated: yes
  • bounded timeout: 45 seconds
  • timed out: no
  • exit status: 0
  • provider/source: claude / claude
  • structured usage payload returned: yes

Runtime ownership/prompt audit:

  • Security descendants: 0
  • Claude-owner Security descendants: 0
  • unowned Security descendants: 0
  • unified-log visibility canary: observed
  • attributable prompt/authorization events: 0

Automated gates on the same candidate:

  • 115 tests across 15 ownership/routing/account/cache/debug/prompt-safety suites: passed
  • 2 opt-in live ownership/auth tests: passed
  • SwiftFormat and strict SwiftLint on the changed Swift surface: passed
  • shell syntax and diff checks: passed

Behavioral boundaries covered:

  • app-owned OAuth credentials retain first priority
  • only typed credential absence reaches the authenticated owner CLI
  • corrupt/unavailable credentials, service failures, selected accounts, and CLI-runtime OAuth remain fail-closed
  • Auto remains CLI → Web; explicit OAuth never falls through to Web

Environment caveats, included for completeness:

  • stock make check reaches the repository's existing Node 25 docs/site.js CommonJS-mode mismatch; the equivalent ESM-mode syntax check passes
  • exact clean-source make test isolates one unrelated date-sensitive existing failure at SpendDashboardControllerTests.swift:495; all Claude-focused tests pass, and the local stabilization for that test is deliberately excluded from this PR

No account identity, token, usage amount, raw Keychain value, raw log, or private artifact path is included or uploaded.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 22, 2026

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

Re-review progress:

@ProspectOre
ProspectOre marked this pull request as ready for review July 22, 2026 05:29

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3d0dc5e09f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeOAuth/ClaudeOAuthCredentials.swift Outdated
@ProspectOre

Copy link
Copy Markdown
Contributor Author

Redacted exact-head proof

This supersedes the earlier proof and validates exact head b12c844e435f0e14610e575e0641a0eb6ba37917, including the Auto-order correction that resolves ClawSweeper's prior P1 finding.

  • clean source snapshot matched the exact PR head; Release binaries were built fresh from that snapshot
  • focused ownership, routing, account-isolation, cache, timeout, and prompt-safety matrix: 218 tests across 22 suites passed
  • broad Claude regression matrix: 637 tests across 98 suites passed, plus 19 tests across 4 secondary suites passed
  • opt-in live matrix: 2 tests in 1 suite passed
  • live app Auto transition exercised safe OAuth absent → authenticated owner CLI success; CLI exit 0, no timeout
  • all 4 first-party Release executables audited: 0 known foreign-Keychain-reader markers
  • runtime audit: owner authenticated; 0 unowned Security descendants; log canary observed; 0 attributable prompt/authorization events
  • SwiftFormat, strict SwiftLint, documentation links/index, shell syntax, and diff checks passed

The public proof intentionally excludes account identity, credentials, token values, usage amounts, raw Keychain records, raw unified-log lines, and private filesystem paths.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 22, 2026

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

Re-review progress:

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b12c844e43

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Scripts/verify_1844_live.sh Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b00d85e90b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBar/UsageStore+ClaudeActiveAccountIdentity.swift Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7e6e23ff73

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeOAuth/ClaudeOAuthCredentials.swift Outdated
@ProspectOre

Copy link
Copy Markdown
Contributor Author

Exact-head redacted proof for 7e6e23ff73f93e903f430ffda9df667eaabaa4c7:

  • clean source snapshot and freshly signed Release bundle
  • focused ownership/routing/account/cache/timeout matrix: 219 tests / 22 suites passed
  • opt-in live owner path: 2 tests / 1 suite passed
  • live App Auto transition: safe OAuth absent → authenticated Claude owner CLI succeeded (exit 0; no timeout)
  • 4 first-party Release executables audited: 0 foreign-reader markers
  • process/log audit: 0 Security descendants, 0 unowned Security descendants, 0 attributable prompt/authorization events
  • legacy-cache compatibility is migration-only for the exact historic default profile; custom/cross-profile cache entries remain fail-closed
  • explicit OAuth recovery is tested: when safe credentials and an owner session are absent, the menu offers Open Terminal for the Claude owner login flow—not a foreign Keychain read and not silent Web switching

Raw account identity, credentials, tokens, usage values, Keychain records, logs, hashes, and local paths are intentionally excluded.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 22, 2026

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

Re-review progress:

@ProspectOre

Copy link
Copy Markdown
Contributor Author

CI follow-up: the current aggregate failure is the unrelated date-sensitive SpendDashboard test group, not the Claude ownership change. It is isolated in draft PR #2390; this branch remains unchanged.

@ProspectOre

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Please publish the exact-head review for 7e6e23ff73f93e903f430ffda9df667eaabaa4c7. The prior exact-review worker completed successfully but its final result was not published; the only visible result is its stale “review started” placeholder.

@ss251

ss251 commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Independent exact-head validation found a test-safety gap; focused follow-up submitted

I ran Scripts/verify_1844_live.sh from exact head 7e6e23ff73f93e903f430ffda9df667eaabaa4c7 in a clean validation clone. Release packaging succeeded, but Phase 1 stopped before the live runtime phases: 219 tests / 22 suites produced 31 issues because the standard test process inherited the installed app's persisted Claude prompt policy and could fall through to the developer's real Claude credentials path/pending-clear state.

That means this run did not reach the owner-CLI process/log audit; it did not modify the real credential or ACL, and I am not presenting it as a passing live proof. The failures are the concrete, independently useful gap now addressed by #2441 at b6f157cccb22b7c0dab79b6d9c93591f15262b32:

  • isolate prompt defaults and credential-file resolution under standard tests;
  • isolate pending cache-clear state per test scope;
  • preserve captured prompt policy across detached delegated-refresh work;
  • require CODEXBAR_ALLOW_TEST_KEYCHAIN_ACCESS=1 before live proof can inspect real user state.

Focused validation on the follow-up passed, cross-provider review completed with no remaining findings, and the P2 live-proof review thread is resolved. The unrelated SpendDashboard stabilization was deliberately removed because #2390 already owns it.

The live reproduction proving that Always Allow succeeds and then is lost after foreign-item replacement is recorded in #1823: #1823 (comment)

Once #2441 is available on this branch (or equivalent isolation is applied), the verifier should be rerun with the explicit live opt-in so Phase 1 cannot be host-state dependent and the process/log ownership audit remains meaningful.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8cf84bb793

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeOAuth/ClaudeOAuthCredentials.swift Outdated
Comment thread Sources/CodexBar/UsageStore+Refresh.swift Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b12e060f93

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBar/UsageStore+Refresh.swift Outdated
@ProspectOre

Copy link
Copy Markdown
Contributor Author

Verification follow-up — 9ba5485bbe4b7361d30e667ed83a9baa985fd2bf

The product code remains the same as the prior live-proof commit; this update makes the verifier reproducible from a clean macOS checkout. SwiftPM's test helper was omitting Sparkle's binary framework from its own runtime lookup path. The verifier now links the resolved framework into the helper's expected build-only lookup location.

  • clean Release packaging passed
  • clean-checkout framework-loader regression passed: 34 targeted tests / 3 suites
  • prior redacted app-Auto live proof remains applicable to the unchanged product code (bounded owner-CLI fallback, structured result, no prompt/authorization events, and no foreign-Keychain reader markers)
  • no account identities, credentials, tokens, usage values, Keychain records, raw logs, or artifact paths are published

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 24, 2026

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9ba5485bbe

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeOAuth/ClaudeOAuthCredentials.swift Outdated
@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

1 similar comment
@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Bravo.

Reviewed commit: d6138ae87f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 30d8655967

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBar/UsageStore+Refresh.swift Outdated
Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeOAuth/ClaudeOAuthCredentials.swift Outdated
@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

@ProspectOre

Copy link
Copy Markdown
Contributor Author

Exact-head validation — c5950d1fec8e9ca576fe14b35baae26f41dd113a

  • profile-scoped deferred-cache cleanup: 17 tests passed
  • Claude profile-cache routing and migration: 6 tests passed
  • account-identity reconciliation, including Auto → OAuth: 20 tests passed
  • test-state isolation: 3 tests passed
  • opt-in live macOS proof: 3 tests passed
    • with the safe OAuth credential intentionally absent, App Auto tried OAuth then succeeded through the authenticated Claude owner CLI
    • the test asserts direct access to Claude Code's Keychain item remains disabled

No account identities, credentials, tokens, usage values, Keychain records, or local paths are included.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 24, 2026

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3e4f4955cb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ProspectOre

Copy link
Copy Markdown
Contributor Author

Layer 1 is dropped as requested. #2380 is rebased onto merged #2441 (962205858c34733a9326947335c1f1cf7b25b4e4) at exact head 3e4f4955cb90132dae64ad6d9a430c3df6907f49.

Exact-head verification after the rebase:

  • canonical make test: 731/731 selections across 61/61 groups, zero first-pass failures/retries/timeouts
  • focused profile/coordinator/debug matrix: 23 tests / 3 suites passed
  • make check: SwiftFormat 0/1593; SwiftLint 0 violations/1592
  • git diff --check: passed
  • CI: https://github.com/steipete/CodexBar/actions/runs/30401170526

For the new #2484 extraction, I also prepared a clean residual stack on top of its current cf09db56 head. The residual final tree is byte-for-byte identical to this tested #2380 head. I am holding the public #2380 restack until #2484 lands so its base does not churn twice.

The two open #2484 environment-routing findings are already covered by that residual stack; a minimal foundation-only patch with 3/3 focused tests and make check green is attached here: #2484 (comment)

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fe0171b584

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeCLISession.swift

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a49d5197fa

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeCLISession.swift
Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeCLISession.swift
@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a49d5197fa

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeCLISession.swift
Comment thread Sources/CodexBarCore/Providers/Claude/ClaudeCLISession.swift
@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: 39065009d1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

Please review exact head 3906500; the prior trigger has not been acknowledged.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 39065009d1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

Please review exact head 911b4b6 after the profile ownership-evidence fix.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 911b4b698b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

Exact head: 72916db

Latest fix preserves selected-profile OAuth authority over unrelated global MCP-only Keychain state across credential loading, strategy availability, and delegated refresh. Local proof: focused routing suites 42/42; make check green; canonical make test 732/732 selections, 61/61 first-pass groups, zero retries and zero timeouts.

@ProspectOre

Copy link
Copy Markdown
Contributor Author

@codex review

Exact head: c852ad4

CI lint follow-up: the selected-profile strategy regression moved into its own suite because the current merge base made ClaudeOAuthFetchStrategyAvailabilityTests 801 lines (limit 800). Production code and assertions are unchanged. Local proof after the split: focused OAuth routing suites 42/42; make check green with SwiftFormat 0/1595 and SwiftLint 0/1594. The preceding exact production tree also passed canonical make test 732/732 selections in 61/61 first-pass groups with zero retries and zero timeouts.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: c852ad4073

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ProspectOre

Copy link
Copy Markdown
Contributor Author

Exact-head local verification completed for c852ad4: canonical make test passed 733/733 selections across 62/62 first-pass groups, with zero failed groups, retries, recoveries, or timeouts. The one live-account test remained intentionally skipped because LIVE_TEST is disabled; all isolated fake-data regressions ran and passed.

@ProspectOre

Copy link
Copy Markdown
Contributor Author

Exact-head CI is fully green for c852ad4: https://github.com/steipete/CodexBar/actions/runs/30411136486

  • aggregate lint-build-test: passed
  • macOS Swift test shards 0/2 and 1/2: passed
  • Linux x64, Linux arm64, and Linux musl: passed
  • lint and GitGuardian: passed
  • canonical local make test: 733/733 selections across 62/62 first-pass groups, zero failures/retries/recoveries/timeouts
  • local make check: SwiftFormat 0/1595; SwiftLint 0/1594
  • latest exact-head Codex review: no major issues
  • unresolved non-outdated review threads: 0

The prepared residual stack on #2484 still has the identical tree (254fc91fa3a0542ca92ddd7957b61cb20908f78e). I am holding the final restack and ClawSweeper re-review until the maintainer updates/lands #2484, so those results are not invalidated by another base change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-risk: 🚨 auth-provider 🚨 Merging this PR could break OAuth, tokens, provider routing, model choice, or credentials. merge-risk: 🚨 compatibility 🚨 Merging this PR could break existing users, config, migrations, defaults, or upgrades. merge-risk: 🚨 security-boundary 🚨 Merging this PR could weaken sandboxing, authorization, credentials, or sensitive data. P1 Urgent regression or broken agent/channel workflow affecting real users now. proof: sufficient Contributor real behavior proof is sufficient. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants