Port upstream CodexBar 0.50.0 - #339
Conversation
…Kimi lanes, menu-card wrap
…gCat token-packs, OpenCode PAYG billing
|
Thermo-nuclear code-quality review: the Wave 0.50.0 increment itself is reasonably decomposed, but this cumulative PR inherits the blocker from #338. Its tree still contains the OpenCode billing addition that pushes |
|
Follow-up thermo-nuclear review on head Please decompose the OpenCode billing subsystem in #338 and restack/rebase this PR afterward. Still blocked via the stack. |
…edrock guidance, status last-success
Stabilize flaky test_run_sends_script_through_pty: the PTY echo test used a 2s idle timeout which is too tight on slow CI VMs — cmd.exe's banner appears but the echo output arrives after the idle window closes, leaving only the banner and failing the CODEXBAR_PTY_OK assertion. Widen timeout to 15s, idle timeout to 6s, and add a 1s initial delay so the shell is ready before the script is sent.
6d5a1cb to
95ea433
Compare
Port of upstream steipete/CodexBar v0.50.0 (stacked on #338; read-only consumption of tagged sources, zero upstream contact).
Ported
providers/cursor/app_auth.rs: reads Cursor's read-onlystate.vscdb(%APPDATA%\Cursor\User\globalStorage) forcursorAuth/accessToken, rebuilds theWorkosCursorSessionTokencookie from the JWT subject, and Automatic mode tries it before browser cookies. Validated sessions persist via the cookie-header cache (15-min TTL so the app's own token rotation wins); a rejected app session logs and falls back to the browser import. SQLite opened read-only with 250ms busy timeout + immutable-mode retry only when WAL sidecars are gone. 4 unit testsget_daily_token_historyin the cost scanner (Codex exact local totals from the packed-days cache; Claude from the de-duplicated record walk).ProviderChartDatacarriestokensHistory+tokensIncomplete(Codex backfill not yet at window depth → "Refreshing" marker). Settings charts gain a Tokens tab, defaulting active for Codex; newTokensHistoryChartwith integer formatting. Locale keysDetailChartTokens/DetailChartRefreshingadded to all 7 catalogs (check-locale green). 4 new frontend tests + serde roundtripauth.json+ custom backend (chatgpt_base_urlor non-OpenAImodel_provider, e.g. Bedrock) now reports that ChatGPT rate limits are unavailable instead of telling the user tocodex login. Detection unit-testedfetch_provider_statuskeeps a process-wide cache of the last successful result; transport failures never replace it — long-running consumers (hooks watch, serve) keep the last known status instead of dropping to unknownSkipped (no counterpart)
Deferred (evidence)
Commands run
cargo fmt --allcargo clippyboth manifests--all-targets -- -D warningscargo test --manifest-path rust/Cargo.toml --lib— 1248 passedcargo test --manifest-path apps/desktop-tauri/src-tauri/Cargo.toml— 342 passedpnpm --dir apps/desktop-tauri test— 261 passed (incl. new ChartsSection tests)pnpm --dir apps/desktop-tauri run build— ok (locale drift check green)UI proof
The Tokens tab + Refreshing marker change the Settings → Providers charts surface. CUA proof pending a fresh
tauri:build:debugcapture pass (planned together with #336's seed tooling); jsdom tests cover the tab-default and marker logic meanwhile, called out per the PR template.