Commit Graph
22925 Commits
Author SHA1 Message Date
Neil d0c4b5432f feat(cloud): SEC-4 design tweaks - 'A former teammate' / 'Someone' fallbacks, wider who column 2026-11-12 18:02:57 -08:00
Neil 53cdc4edfd test(cloud): SEC-4 window test re-mints tokens; fixture activity newest first 2026-11-12 18:01:37 -08:00
Neil a5a1343a11 feat(cloud): SEC-4 customer-visible secret activity log (create/update/delete, names only, 90 days, owners/admins) 2026-11-12 17:16:36 -08:00
Neil b16f430738 Merge pull request #589 from nwparker/cloud/w6-iat-backdate
fix(cloud): IAT-BACKDATE-GAP member-change/removal checks allow for auth's 30 s iat backdate
2026-11-12 17:08:32 -08:00
Neil 2f5e89cc35 Merge pull request #585 from nwparker/cloud/w6-vm-scripts-stamp
fix(sandbox-control): never install older VM scripts over a newer golden (VM-SCRIPTS-DOWNGRADE)
2026-11-12 17:04:27 -08:00
Neil 63c4d367ef fix(cloud): IAT-BACKDATE-GAP member-change and removal checks compare the mint time (auth backdates iat 30 s); harness mints like auth 2026-11-12 16:59:25 -08:00
Neil ae1127bfd7 Merge pull request #584 from nwparker/cloud/w6-org-mismatch
fix(cloud): ORG-TOKEN-STALE Worker backstop (x-orca-org 409 org_mismatch; stale_token on create/secrets/GitHub)
2026-11-12 16:57:52 -08:00
Neil 018d81b096 fix(sandbox-control): never install older VM scripts over a newer golden (VM-SCRIPTS-DOWNGRADE)
The generator now emits VM_SCRIPTS_HASH and a monotonic VM_SCRIPTS_STAMP
(kept while the scripts are unchanged; max(previous + 1, now) on a change).
Provisioning records the stamp in /opt/orca/bin/.scripts-stamp (source
builds use the fetched commit's stamp), installEntryPoints writes the
Worker's, and ensureEntryPoints probes stamp + marker in one command and
skips images whose stamp is newer than the Worker's. Golden refreshes use
ensureEntryPoints too, so a lagging Worker cannot bake older scripts into
a refreshed golden.
2026-11-12 16:52:50 -08:00
Neil 34d86a539a fix(cloud): stale_token on create/secrets/GitHub allows for auth's 30 s iat backdate, so the desktop's one re-mint succeeds 2026-11-12 16:50:53 -08:00
Neil 006676a59b fix(cloud): ORG-TOKEN-STALE Worker backstop: x-orca-org mismatch -> 409 org_mismatch; role-changed token -> 401 stale_token on create, secrets and GitHub 2026-11-12 16:49:00 -08:00
Neil 9c18966cba Merge pull request #577 from nwparker/cloud/env-origin-toast
fix(cloud): 'Cannot reach remote origin' only after a confirming check, with Check again (ENV-ORIGIN-TOAST)
2026-11-12 16:44:15 -08:00
Neil 54a5cd5f56 Merge pull request #579 from nwparker/cloud/w6-push-notfound
fix(cloud): GitHub not-found on push/fetch: check the name, or install the App if private
2026-11-12 16:37:03 -08:00
Neil 4bdcac157a Merge pull request #576 from nwparker/pl/wake-billing-card
fix(cloud): PAIRED-BILLING a wake the plan refused says why, never the code
2026-11-12 16:32:23 -08:00
Neil 57649ed582 Merge pull request #581 from nwparker/cloud/premerge-e2big
fix(premerge): run targeted vitest files in batches (E2BIG on wide PRs)
2026-11-12 16:21:06 -08:00
Neil 1fe5573222 fix(premerge): run targeted vitest files in batches (E2BIG on wide PRs like #574)
A PR that deletes or changes widely imported modules selects hundreds of
test files; passing them all to one vitest spawn failed with E2BIG. Run them
in batches of PREMERGE_TEST_BATCH (default 150); every batch must pass, so
the gate and the premerge OK record are unchanged.
2026-11-12 16:18:42 -08:00
Neil 4f2b3772ca fix(cloud): GitHub not-found on push/fetch says to check the name, or install the App if it's private (design-squad) 2026-11-12 16:14:15 -08:00
Neil a196091d55 Merge pull request #578 from nwparker/cloud/w6-push-no-prompt
fix(cloud): PUSH-RAW-PROMPT github.com push with no credential never prompts
2026-11-12 16:13:22 -08:00
Neil cc62955616 test(cloud): resume-stuck waits for the resuming claim instead of a fixed 10 ms (flaked under load) 2026-11-12 16:09:57 -08:00
Neil 636cfcf1f2 copy(cloud): say what an unreachable remote means: 'Pulls and pushes won't work until it can.' (design-squad, ENV-ORIGIN-TOAST) 2026-11-12 16:09:37 -08:00
Neil 3de6f16d82 fix(cloud): VM git lines point to Settings › Account (true with or without billing; design-squad) 2026-11-12 16:05:27 -08:00
Neil 61d31da441 fix(cloud): PUSH-RAW-PROMPT a github.com push, pull or fetch with no credential never prompts; one plain line says what to do 2026-11-12 16:04:07 -08:00
Neil dedecde23c Merge pull request #575 from nwparker/create-speed/gh-create-sheet
feat(cloud-create): GitHub-only Orca Cloud create shows the full build sheet (GH-CREATE-SHEET)
2026-11-12 16:02:07 -08:00
Neil 62b6349cec test(cloud): fixtures for the can't-reach-GitHub line (ENV-ORIGIN-TOAST) 2026-11-12 16:01:44 -08:00
Neil 0361eb4705 fix(cloud): 'Cannot reach remote origin' only after a confirming check, with Check again (ENV-ORIGIN-TOAST)
The create's environment check runs right after the sandbox answers. A failed
'git ls-remote origin HEAD' (git.fetch) fell through triage to a generic 'check' notice: the
in-workspace Workspace setup toast showed the doctor's bare label with no action. A fresh sandbox
can briefly miss its GitHub credential, so the line now waits for two confirming checks (5 s, then
15 s) and shows only if origin still doesn't answer, as 'This workspace can't reach <repo> on
GitHub right now.' with Check again (re-runs the check, drops the line once it passes).
2026-11-12 16:00:18 -08:00
Neil a2d49d00a2 fix(cloud): PAIRED-BILLING design-squad: hours used turns overage on here and wakes again; Compare plans
Hours used: an owner's fix is the create sheet's [Turn on with a $X cap] (billing's default cap; plain
Turn on overage without one), applied in place, then the wake runs again. Plan ended: Compare plans,
the one label for that action (also on the Restart/Sleep failure toast). Drops the private
orcaCloudWorkspace.error.seePlans key it no longer uses.
2026-11-12 15:54:54 -08:00
Neil 062d85cec6 fix(cloud): PAIRED-BILLING a wake the plan refused says why, never the code
The waking card showed the control plane's code on a billing refusal (paired: "entitlement_denied";
owned: "Orca Cloud refused the request (entitlement_denied).") and offered Restart, which fails the
same way. Failed wake/restart/unarchive events now carry the plan's refusal (billingDenial), from
main's recipe resume, restart and unarchive and from the paired wake. The card uses the create
sheet's billing words, offers the one fix to an owner or admin (See plans, Raise spend cap, Update
payment method) and tells a member who to ask; running limits keep the shared workspace copy.
2026-11-12 15:45:37 -08:00
Neil 00205419f8 fix(cloud): PAIRED-WAKE (1/2) a sleeping paired cloud workspace wakes when opened, on focus and on hover (#571)
* fix(cloud): PAIRED-WAKE (1/2) a sleeping paired cloud workspace wakes when opened (sidebar, Home), on focus and on hover, like an owned one

cloudWorkspaces:wake wakes a paired workspace's sandbox through the control plane (this desktop has
no VM record to resume) and reconnects its bound server at once. Opening its sidebar row wakes it
when asleep (waking overlay, failure card), and Home > Open wakes it before connecting to the saved
pairing. Predictive wake treats a sleeping paired workspace as a candidate with the same preflight
(fresh status + billing caps) and wakes it quietly (coordinator decision). Wake progress never adds
a paired row to the owned ids.

* fix(cloud): PAIRED-WAKE localize the not-paired message; test uses fixed timestamps

* fix(cloud): PAIRED-WAKE design-squad copy for the not-linked wake failure
2026-11-12 15:27:56 -08:00
Neil ac06c09040 feat(cloud-create): a GitHub-only Orca Cloud create shows the full build sheet (GH-CREATE-SHEET)
Starting a cloud workspace from a GitHub repository with no clone here showed only a
'Starting <repo> in Orca Cloud…' toast. It now opens the same build sheet as a cloud
create from a local clone: Start sandbox, Clone repository with git's progress, Open
workspace; the same failure cards and JA-21b billing blocker (plan, hours, spend cap,
payment; members get no See plans); Retry; and Back to draft (composer back on Orca
Cloud with the GitHub repository picked and the prompt kept).

Main: createFromGitHub runs the hosted driver's create path (createSandboxWithProgress,
shared with the owned create): boot plan, create, waitForClone, with the same
[orca-cloud] progress lines streamed on ephemeralVm:provisionEvent under the window's
creation id, the same failure reason lines and codes (hostedCreateFailure), Cancel via
ephemeralVm:cancelProvision, and an Idempotency-Key. The workspace id is fixed per
creation so a Retry sends the same body.

Renderer: the GitHub start is a pending creation with the Orca Cloud recipe and a
githubSource; retryBackgroundWorktreeCreation routes it to its own runner. A Retry
after a lost answer resends the same key (same sandbox back); after an answered failure
it is a new attempt; after a failed open it only opens the sandbox it already has.
The paired workspace has no environment-checks step.
2026-11-12 15:26:26 -08:00
Neil 433add6c42 fix(cloud): copy workspace link through the main-process clipboard (#573)
The W-number chip, Home's Copy link, the menu items and the copy-link
shortcut all went through navigator.clipboard.writeText after an awaited
control-plane lookup. Electron rejects that write once the document has
lost focus or user activation (always true from the menu or a shortcut),
so the copy failed with "Couldn't copy the link". Use
window.api.ui.writeClipboardText like every other renderer copy, make the
link lookup never reject (3s cap, sandbox-id link fallback for paired or
offline devices), and keep the error toast for real clipboard failures.

The chip tooltip now also says who the link is for.
2026-11-12 15:19:05 -08:00
Neil 09ed99034e fix(cloud): PAIRED-NO-ROW a paired cloud workspace keeps its sidebar row (P0 regression from #562) (#570)
* fix(cloud): PAIRED-NO-ROW a paired cloud workspace keeps its sidebar row (paired servers left out of team scoping)

Since #562 a paired "<name> (cloud)" server counts as Orca Cloud, so selectOrcaCloudHostScopeKey
scoped it by team. Its owner is never in cloudAccountIdByEnvironmentId (this desktop's own runtimes
only), so it landed in hiddenHostIds and every row and project of a paired workspace vanished, a
GitHub-only create included (n37 P-paired). Paired servers are left out of that scoping, as before
#562.

* test(cloud): PAIRED-NO-ROW typed repo literal
2026-11-12 15:05:52 -08:00
Neil 77efed3630 fix(cloud): PAIRED-STATUS one status path for paired cloud workspaces (#566)
* fix(cloud): PAIRED-STATUS one status path for paired cloud workspaces (main resolves a bound pairing; store registers paired rows)

getStatus/getArchive take { workspaceId, environmentId? }: main resolves this desktop's own runtime
first, else a paired server bound to a sandbox (findCloudSandbox), never an arbitrary sandbox.
The window registers each paired cloud workspace's own row (main checkout on a server the catalog
marks orcaCloudPaired) in the cloud workspace store's `paired` map, apart from the owned ids, so its
status lands in status[worktreeId] and every status surface reads it unchanged.

* fix(cloud): PAIRED-STATUS read worktrees through selectWorktreesByRepo (workspace-record ratchet)
2026-11-12 14:42:59 -08:00
Neil b7289bd34e Merge pull request #567 from nwparker/cloud/chat-cancel-error
fix(cloud): CHAT-CANCEL-ERROR held structured chats show no error cards; Cancel keeps the chat held
2026-11-12 14:38:42 -08:00
Neil 17d0405965 fix(cloud): CHAT-CANCEL-ERROR held structured chats show no launch/session error cards; Cancel keeps the chat held 2026-11-12 14:30:09 -08:00
Neil 06cb139a57 Merge pull request #561 from nwparker/cloud/v3-01b-structured-restore
fix(cloud): V3-01b a held structured chat keeps its hold across a restart; DUP-EXPIRED-STRIP
2026-11-12 14:29:52 -08:00
Neil 0fd98c5c2a fix(cloud): PAIRED-SLEEP sleep a paired cloud workspace's sandbox through the control plane; paired-from-birth rows are cloud rows from the catalog mark (#565)
Sleep on a paired cloud workspace's own row (no local VM record) now stops its sandbox via
cloudWorkspaces.sleep(sandboxId), so it stops billing; failures reuse the cloud sleep toast.
useIsCloudHostRow / isCloudPrimaryRowNow also read the runtime catalog's orcaCloudPaired mark,
so a GitHub-only create loses its "primary" badge and gets "Delete workspace…" and Sleep without
waiting for the pairing bindings to load.
2026-11-12 14:26:49 -08:00
Neil 0bab6a9c4c fix(cloud): PAIRED-CHROME paired rows get the cloud context menu (Copy workspace link, Delete alone, no Lineage/Project group) (#564) 2026-11-12 14:16:56 -08:00
Neil 1eb74abddf fix(cloud): NAME-DROPPED a GitHub-only cloud create keeps the typed name as the workspace title (#563) 2026-11-12 14:11:51 -08:00
Neil 511047b5fd fix(cloud): V3-01b an unread restored hold takes the account read once it lands (found in the real proof)
The proof's first restart showed "couldn't check your sign-in" on a chat whose
account read returned 'none' a moment later: a hold restored before the read
landed stayed 'unread'. The account watch now turns it into the read's answer
(isn't set up / expired / covered); it still never starts.
2026-11-12 14:07:08 -08:00
Neil d04cbb4da1 fix(cloud): PAIRED-AWARE (1/3) paired Orca Cloud servers count as Orca Cloud for every check (#562)
* fix(cloud): PAIRED-AWARE paired Orca Cloud servers count as Orca Cloud everywhere (catalog marks bound servers; shared check and sandbox map include them)

* fix(cloud): PAIRED-AWARE paired-server mark held in memory from bindings reads and writes (no sync fs on main); catalog republishes on change
2026-11-12 14:04:45 -08:00
Neil 585c163ae1 fix(cloud): V3-01b review: one hold per key from the moment it is asked for; joined marks only for restored holds; only the sign-in verdict gives way
- holdCloudAgentLaunch registers its outcome before awaiting the account read,
  so startup and the launch's retry asking at once share one hold (no orphaned
  hold, no hung launch). resumeChat leaves a hold the retry already owns.
- joinedSessions is marked only when the joined hold was put back at startup.
- useCloudHeldChatUnavailable hides only the not-signed-in verdict.
2026-11-12 13:37:44 -08:00
Neil 1c58febcf0 Merge pull request #560 from nwparker/lc2/cloud-primary-delete
fix(cloud): CLOUD-PRIMARY-DELETE a cloud workspace on its default branch is deletable (Delete workspace… destroys the sandbox)
2026-11-12 13:34:37 -08:00
Neil 42f62ba4ff Merge pull request #559 from nwparker/cloud/w6-setup-paste-focus
fix(cloud): SETUP-PASTE P0 strip code field paste never reaches the terminal
2026-11-12 13:28:27 -08:00
Neil 958de6c246 fix(cloud): V3-01b a held structured chat on Orca Cloud keeps its hold across a restart; DUP-EXPIRED-STRIP
- cloud-structured-held-launch-memory: one record per held structured chat
  (session, workspace, environment, agent), per Orca profile; never prompts
  or secrets; bounded, ages out.
- holdStructuredCloudLaunch remembers a chat while it holds and forgets it on
  settle; a chat with a record holds as restored (a failed or covered read
  waits as awaitingStart, never creates signed out); a launch joins a hold
  already placed for its key (joinCloudAgentHold) instead of holding twice.
  In-session launches are unchanged.
- cloud-held-launch-resume: at the host subscription, each held chat's hold is
  put back as soon as its tab is in the store, whatever becomes of its
  launch's retry (probes that throw leave the hold and strip up). If no retry
  joined it, Start retries the launch once and Cancel abandons it.
- While a chat is held on its cloud strip, the host's not-signed-in verdict is
  the strip's to explain (useCloudHeldChatUnavailable in the structured pane
  notices); unheld chats keep the generic notice.
- DUP-EXPIRED-STRIP: CloudRunningStripPortal yields to a tab-key hold too, so
  a host-published held strip never stacks with the running strip.
2026-11-12 13:21:32 -08:00
Neil ee2aad2740 test(cloud): SETUP-PASTE test doubles through one documented stub (no inline casts) 2026-11-12 13:19:45 -08:00
Neil b8ebb8afea fix(cloud): CLOUD-PRIMARY-DELETE a cloud workspace on its default branch (owned or paired) is deletable: Delete workspace… opens the cloud delete dialog and destroys the sandbox; no primary rule, no Remove Project, no primary badge 2026-11-12 13:18:57 -08:00
Neil 9a0c331dac fix(cloud): SETUP-PASTE P0 a paste into the cloud strip's code field stays in the field; the terminal never takes it (Cmd+V, app menu, paste event, right-click) 2026-11-12 13:14:49 -08:00
Neil 456ae5d4e5 Merge pull request #555 from nwparker/cloud/v3-01-held-restore
fix(cloud): V3-01 a held Orca Cloud launch survives a restart
2026-11-12 13:14:42 -08:00
Neil 20aea027f7 fix(cloud): an expired hold starts only on real coverage (account or key), never while the agent is paused or withdrawn
composer-redo's #555 note: cloudAgentHoldReason returns null for killSwitch and
unavailable, so the account watch started an expired hold while the agent was
paused or withdrawn. Proceed only when coverage is 'account' or 'key'.
Tests: kill switch keeps it held, a renewal then starts it; the in-session
cases move to their own describe.
2026-11-12 11:57:25 -08:00
Neil df079c08a9 Merge pull request #558 from nwparker/cloud/v3-08-signed-out-cloud-card
feat(landing): signed-out cloud workspaces sign-in card (V3-08)
2026-11-12 11:55:32 -08:00
Neil c072f6eae9 fix(cloud): an expired hold never auto-starts when its sign-in is removed rather than renewed (found in the V3-01 proof)
holdCloudAgentLaunch's account watch treated any change away from 'expired'
as a renewal, so removing the credential ('none' -> notSetUp) started the
agent with nothing covering it. Proceed only when the account now covers the
agent; a removed sign-in turns the hold into the one-time setup.
2026-11-12 11:53:32 -08:00