Skip to content

Latest commit

 

History

History
24 lines (17 loc) · 2.08 KB

File metadata and controls

24 lines (17 loc) · 2.08 KB

CLI

Improvements

  • Added codex-multi-auth unpin to clear the manual pin set by switch, bump affinityGeneration so the proxy invalidates session affinity on the next request, and resume hybrid rotation.
  • codex-multi-auth status now surfaces the pinned account index and warns when the runtime is using a different account than the pin requests.
  • codex-multi-auth switch <index> now writes pinnedAccountIndex that the proxy honors before session affinity, hybrid scoring, and pool fallback; best clears the pin.

Bugfixes

  • status no longer prints Pinned: account NaN for corrupt pins; the guard tightens to Number.isInteger, shows the raw stored value, and points at unpin.

Runtime Rotation Proxy

Bugfixes

  • Runtime rotation proxy now honors manual switch on the Codex Desktop app via a content-hash-keyed per-path read of the storage file; the pinned path is exempt from markSwitched/saveToDiskDebounced/syncCodexCliActiveSelectionForIndex.
  • Session affinity no longer locks the desktop app to one account for 20 minutes; affinityGeneration bumps from switch/unpin/best trigger SessionAffinityStore.clearAll() before chooseAccount, including for the in-flight request.
  • When the pinned account is unavailable, the proxy now returns HTTP 503 with error.code = codex_pinned_account_unavailable instead of silently rotating.
  • AccountManager.buildStorageSnapshot no longer wipes pinnedAccountIndex/affinityGeneration on routine debounced saves; it refreshes from disk before serializing.
  • Concurrent affinityGeneration increments across CLI processes are now atomic via Math.max(inMemory, disk) + 1.
  • unpin now uses saveAccountsWithRetry so a transient Windows file lock cannot silently lose the user's intent.
  • Replaced a synchronous busy-wait in readStorageMetaFromDisk with a single read plus per-path content-hash cache fallback that preserves the last snapshot on transient errors.
  • Runtime rotation proxy storage cache is now a Map<string, StorageMetaSnapshot> keyed by absolute path, fixing cross-instance and cross-worker pin leakage.