Repository navigation
Conversation
Store write-only API-key entries in protected execution-host storage and poll the documented balance endpoint through the existing account usage service. Display each currency's exact monetary strings in Accounts and the status bar, with explicit unsupported hosts and stale errors. Builds on the DeepSeek balance and mobile account work in #12873 and #23294. Co-authored-by: Wooseong Kim <[email protected]>
Cancel deferred credential refreshes across service shutdown and suppress completed state updates from an aborted lifecycle. Clear the previous balance when a failed protected-file write already replaced the persisted key, while retaining the save error and avoiding an immediate request. Add real loopback regressions for shutdown, successful live rotation, and a durable-write permission failure.
7 of 8 tasks
This branch has not been deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
ELI5
Save a DeepSeek API key on its host and see prepaid balances in CNY and USD. Switching hosts discards unfinished key entry and any pending form result.
What Changed
Before, Orca had no protected DeepSeek account setup or balance display. Accounts now saves encrypted keys through the existing secret store and secure-file writer; the host usage service publishes optional account and balance fields to Settings, the status bar and usage roster. Currency amounts remain exact strings, and replacing or removing a key clears its old balance.
The key-entry form now belongs to one owner lifetime. A→B→A, loading, missing support and unmount discard plaintext, busy state and errors; late completions cannot update a replacement form. Same-owner balance updates preserve typing. Main was merged at
ce0778626618bb9a5197209f5189190f2d51545c; the only semantic merge repair kept main's moved Claude test import.Why
Prepaid money needs currency rows rather than a quota meter. Reusing host-owned account streams, HTTP, encrypted storage and keyed React lifetimes avoids parallel caches and effect-based draft resets.
This credited successor retains Neil [email protected]'s original commits
bdd463b0283cb789b1f7c1fa34118a2306dab815and26ea4b3c14ec947cf2997d109cdc823fcd9165a6unchanged and reachable. It continues the credited work from @innocarpe's desktop PR #12873, with Wooseong Kim's existing credit retained. Predecessors remain open until an actual successor merge.Linked Issue
Fixes #12869
Visual Proof
The existing attachments below are historical synthetic fixture captures from earlier draft revisions, preserved for design context. They are not fresh proof of this merged head; no app, real credentials or authenticated provider was used in this publication run. Fresh rendered/native acceptance remains pending.
Testing
On macOS, the merged tree passed 186 tests across 18 files, full Node/CLI/web typecheck, formatting for 62 feature files, all seven changed-quality scans and unchanged Husky commit checks. Coverage includes the actual 15-second HTTP timeout against synthetic fixtures, protected credential persistence, owner/revision/shutdown fencing, account subscriptions, owner-form replacement, search, status visibility, monetary formatting, hydration and mobile method allowlisting. The independent review's four extra cases ran but remain uncommitted.
The initial merge test run failed because of duplicate Claude imports; main's import was retained and all selected tests passed on rerun. An initial pre-commit quality run compared against the old merge base and flagged two mobile tests inherited from main; the final committed-head check against the fetched base passes, and mobile was left unchanged. No paid provider, keychain or global profile was used. Full-repository lint/test/build, CI and rendered/native checks remain for independent acceptance.
Review
Draft head:
bfbc795e77850438bf9e93ab35ead403b1665035. Coordinator owns independent resulting-head review, CI, readiness, merge and predecessor closure. Separate stacked mobile PR #24808 was not modified and needs the changed desktop base assessed independently.Agent skill upstream boundary
Notes
Protocol remains 3 with minimum 2; balance capability and snapshot fields are additive. SSH/WSL without a protected backend are unsupported with no local fallback; folder workspaces use the same execution-host selector. Mobile permits status and refresh only, excluding key save/remove. Native Windows/Linux, SSH/WSL and paired-host rendering were not exercised.
Checklist