Commit Graph
21823 Commits
Author SHA1 Message Date
Brennan Benson fa5dbeb82b perf: reuse AI-vault title requests across a sync pass until an input changes
The title pass rebuilt every tab's conversation 2 + 2 x batches times per
20 s pass. Keep one request snapshot per sync and rebuild it only when a
conversation, tab, layout or owner input changed; request timing and
titles are unchanged.
2026-11-16 01:50:42 -08:00
Brennan Benson 636d990f34 Keep chat composer state when its view reconnects (#42695)
* refactor: give chat tabs ownership of composer editors

* Retain pasted-text file paths with composer undo history

* Keep composer selection ownership with its editor
2026-11-16 01:36:50 -08:00
Brennan Benson 0f3d81f791 perf(mac): reuse verified terminal names across process-table captures (#43004)
* perf(mac): reuse verified terminal names across process-table captures

Each full macOS process-table capture ran one lstat per terminal on the
machine. On busy Macs that is millions of libuv pool jobs a day in the
terminal daemon, which is the load that wedges macOS's pool and makes
createOrAttach time out (#31926, #42958). Verified ttys names now last 60s;
misses and /dev scan aliases are still read live.

* perf(mac): keep verified terminal names for five minutes

Closed ptys stop reporting their device, so the TTL is only a safety
margin; a longer one removes the largest remaining pool-job source.
2026-11-16 01:30:45 -08:00
OrcaWinandOrcaWin 1c37b4a2e4 test: remove narrow terminal rendering and query-order suites (#43056)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 01:30:01 -08:00
JinjingandClaude 73bbc3ae08 fix(mobile): refuse to publish an Android APK carrying Play's license check (#42973) (#43054)
Play Console's automatic protection injects com.pairip's license check into every
APK Play generates, including the universal APK we republish on GitHub. On phones
where Google Play is disabled or unreachable (mainland China) the check shows
"Something went wrong ... Check that Google Play is enabled" and closes the app.

download_signed_apk now fails before the GitHub release when the APK's dex carries
com/pairip/licensecheck, and the README says to keep automatic protection off.

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-16 01:21:18 -08:00
Brennan Benson b26087ffcc fix(chat): keep the reply before a mid-turn message visible in finished turns (#42335)
* fix(chat): keep replies before a mid-turn message visible in folded turns

A person's message is a boundary that keeps the reply before it, and
back-to-back replies stay visible, matching the common pattern for
completed turns. Tracked in #41393.

* fix(chat): fold a reply followed by its own tool work, judged within its turn

Tool-only rows merge into the reply before them, so a reply row that
draws tools is followed by work, not by the next reply. Adjacency is
judged within each turn, and orphaned tool results are not a person's
boundary.

* fix(chat): keep generated-image operations out of back-to-back replies

A generated-image row stripped of its preview still carries its
operation label; it is work, not a spoken reply.

* fix(chat): fold Codex image views and image status lines as work in finished turns

Codex's "Viewed image" rows and image-status lines ("Image generation failed", "preview unavailable") were stored as plain assistant text, so a finished turn counted them as replies and kept them, plus the sentence before them, visible. The Codex producer now marks them as image operations when it writes them, the same way it already marks generated images, and the fold treats them as work.

Tracked in STA-14968.

* fix(chat): keep response actions on the reply, not an image operation; tighten interleaved-turn fold test
2026-11-16 01:18:53 -08:00
Brennan Benson 8f07f2749a perf(codex): skip singleton trust table classification (#43024) 2026-11-16 01:18:21 -08:00
Brennan Benson 1b87d1be25 fix(browser): free hidden pages based on the current page only (#42830)
* fix(browser): free hidden pages based on the current page only

Earlier back/forward entries no longer keep a hidden browser page alive. Edits,
child frames, audio, picture-in-picture, PDF, capture and file/document URLs on
the current page still protect it; freed pages restore their history as before.

* fix(browser): keep a hidden page whose current document is a POST result

The freed record keeps only URLs, so reopening a POST result would load a
different page by GET.

* fix(browser): restore scroll and form contents when reopening a freed page

Keep Chromium pageState in the in-memory freed-page record so reopen and
Back restore scroll position and form contents. It is never persisted,
logged or sent over IPC, and is dropped when the page closes or restores.

* fix(browser): drop a closed page's freed-page record immediately

* fix(browser): reset background-activity protection when a new document commits

* fix(browser): keep the favicon baseline across commits

* fix(browser): keep title and favicon baselines across commits
2026-11-16 01:17:58 -08:00
OrcaWinandOrcaWin 84da54ae3d test: remove two low-value copy and language retry suites (#43051)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 01:16:18 -08:00
Jinwoo Hong 083a9a8f4d fix(orchestration): count an approved terminal prompt as answered while its tool runs (#42708)
* fix(orchestration): count an approved terminal prompt as answered while its tool runs

* fix(orchestration): a deny counts as answered only once Claude records it

* test(orchestration): stop ticking once the slow allow is answered
2026-11-16 04:14:46 -05:00
Brennan Benson 6db9aabbe1 perf(orchestration): stop orchestration.db growth by pruning settled chat output copies (#42839)
* perf(orchestration): prune settled chat output copies and reclaim orchestration.db space

Background maintenance rewrites chat workers' saved output copies of Runs settled over a day ago
to the reference later releases store, every six hours at a tenth of the thread, and returns
free pages in bounded steps once the file uses incremental auto_vacuum. New databases start
that way; Settings > Agent orchestration can restart Orca to rewrite an existing one.

* fix(orchestration): prune only copies whose chat is readable here, in bounded pages

Pages now examine a fixed window of archive rows and check each Run once, so a large Run
cannot make one slice quadratic. A copy whose chat this host cannot read stays. The restart
rewrite keeps its temporary copy on disk and records a failure for Settings to show.

* fix(orchestration): check chat readability without re-registering released workers

The readability probe builds the identity from the durable row instead of rehydrating it into
the live registry. Free-space checks use SQLite's own temp folder; a page's Run verdicts are
shared across a pass; a failed failure record no longer hides the VACUUM error.

* chore(orchestration): annotate prune casts, follow Button spacing, sync the runtime catalog

* chore(i18n): resync the runtime English catalog after rebase

* fix(orchestration): share Run verdicts across a prune pass; check the temp drive SQLite uses on Windows

* perf(orchestration): compact legacy storage during update shutdown

* test(orchestration): mock filesystem space checks through ESM factory

* Align update maintenance checks with shutdown-only work

* Drop the one-time update VACUUM; keep prune and incremental reclaim

Existing non-incremental orchestration databases stop growing because freed
pages are reused; nothing shrinks them automatically.
2026-11-16 01:01:58 -08:00
Brennan Benson 980352d897 Reduce native chat memory by replacing per-chat Electron supervisors (#42760)
* Launch provider CLIs without a per-chat runtime supervisor

* Initialize process-owner fixtures with an isolated app environment

* Retire provider output transports and failed ownership drafts

* Finish provider stops when the session group empties

* Complete native cleanup from verified watcher exit and cancel held launches

* Let native watcher finish one-shot provider exits

* Retire late ownership records after canceled provider launches settle

* Reap each provider subtree in an isolated native parent

* Preserve provider outcomes and compatibility with native parents

* Publish actual provider identities and retire native parent observers

* Retire numeric writer PIDs when their group is proven absent

* Retire provider transports and accept proven group absence

* Fence retired process identities across asynchronous cleanup

* Use native timer types and readonly process fixtures

* Reuse bounded timeout for compatibility output drain

* Release launch scopes held by late transport error handlers

* Keep processless launch failures out of watcher waits

* Align lifecycle validation with final ownership contracts

* Remove duplicate helper preparation from the dev launcher

* Keep legacy fallback in place and simplify native ownership handoff

* Defer background provider maintenance until the first window

* Release startup hook maintenance for terminal launches

* Use relocated artifact module in native prebuild scripts

* Preserve agent failure outcomes and clean tools before ownership is lost

* Budget ownership capture for its bounded identity reads

* Keep lifecycle regressions at their behavior-owning seam

* Explain the fake-clock process-read fixture

* Capture tool ownership before restart recovery removes the CLI

* Skip descendant inventories for absent provider roots

* Make final output drain regression test deterministic

* Keep output drain fixture assertions type-safe with IPC

* Use existing provider fixtures across Node and Bun

* Prepare native provider helper for Codex contract CI

* Verify provider ownership using its recorded start precision

* Preserve exact provider ownership through reader failures

* Retire exhausted recovery records without blocking watcher cleanup

* Distinguish exited descendants from unreaped zombies

* Preserve group retirement without trusting an exited root

* Keep CLI input owned through native parent loss

* Keep watcher cleanup proof through lost-parent retirement

* Guard retirement against late watcher cleanup proof

* Contain provider launches that fail before stdio setup

* fix(claude): preserve startup diagnostics after input pipe failures

* fix(provider): capture lost outcomes before native completion cleanup

* fix(provider): retire speculative captures after a valid outcome

* fix(provider): share spawn absence classification through its existing boundary
2026-11-16 01:01:24 -08:00
OrcaWinandOrcaWin 348bc2a7b8 test: remove two low-value settings and update disclosure suites (#43046)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 00:59:30 -08:00
Jinwoo Hong 0fed4ae395 fix(orchestration): page chat worker reads before bounding and keep their fleet projection (#42707)
* fix(orchestration): page chat worker reads before bounding and keep their fleet projection

* test(orchestration): cover byte-clipped chat worker pages
2026-11-16 03:58:20 -05:00
Jinjing 03e4333b8d chore: simplify card introduction comments (#43040) 2026-11-16 00:48:20 -08:00
OrcaWinandOrcaWin 1964094cbc test: remove two low-value preference and presentation suites (#43041)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 00:46:59 -08:00
Neil 930f032dff fix(sidebar): keep delete dialog height stable and show full ignored-files list (#42995)
* fix(sidebar): keep delete dialog height stable and show full ignored-files list

* Replace delete dialog file popovers with inline collapsible sections
2026-11-16 00:42:46 -08:00
a5781b8c15 fix(i18n): translate the local host label and Orca restart notes (#43012)
The unrenamed local host label ("Local Mac") and the four restart
continuation notes the host journals in English stayed English in every
UI language.

selectExecutionHostDisplayLabel and the automation host labels now
resolve the local host through the translated label, and desktop and
mobile notice rows map the exact English restart-note text to catalog
keys at display time, so saved chats and older servers read translated
too. Renamed hosts still show as typed.

Co-authored-by: x-Ai <5061489+x-Ai@users.noreply.github.com>
Co-authored-by: Neil <neil@stably.ai>
2026-11-16 00:38:19 -08:00
Jinjing 7210c12930 feat(sidebar): introduce new worktree cards (#43028) 2026-11-16 00:37:11 -08:00
OrcaWinandOrcaWin 797e648a21 test: remove three low-value cache and presentation suites (#43035)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 00:33:32 -08:00
7839c9ae48 fix(i18n): fill Simplified Chinese coverage gaps on desktop and mobile (#43011)
Add 361 desktop and 633 mobile translations for English keys that still
fell back to English: workspace cleanup, the MCP server panel and sign-in
requests, subagent views, automation runs, worktree cards, Memory Saver,
account rename, PR updates and the freeze report on desktop, and most of
the mobile pull request, source control, tasks, agents and session screens.

Mobile code often calls a plural key literally as t('key_one') when the
count is 1, and i18next looks that key up as written, so zh showed English
for a single item. Add the explicitly called _one keys, each equal to its
_other value.

Also correct two browser search keywords that rendered cookies as 曲奇饼,
and entries that called archive scripts 存档 where the catalog says 归档.
The worktree cards "New" badge keeps 新功能 via a key override, mobile
"Start workspace" matches the desktop wording, and an automation's Active
status and list group read 已启用 (paired with 已暂停) instead of 当前.

Co-authored-by: x-Ai <5061489+x-Ai@users.noreply.github.com>
Co-authored-by: Neil <neil@stably.ai>
2026-11-16 00:27:44 -08:00
OrcaWinandOrcaWin 0c359c3cf6 test: remove four low-value preference and presentation suites (#43029)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 00:23:09 -08:00
OrcaWinandOrcaWin 4fcdfeddfd test: remove nine low-value renderer and preview suites (#43025)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 00:07:14 -08:00
OrcaWinandOrcaWin 06795b179f test: remove six low-value suites and trim MCP inspection coverage (#43017)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-16 00:00:23 -08:00
Steve AshandNeil 396f14d904 fix(ssh): close system SSH stdin for commands that send no input (#42862)
Windows OpenSSH (seen with OpenSSH_for_Windows 9.5p2 behind a ProxyCommand)
can keep ssh.exe alive after the remote command exits while its stdin pipe
is still open, so connects and orcad installs stall until the 30s timeout.

spawnSystemSshCommand now takes a closeStdin option that ends the child's
stdin right after spawn, and SshConnection.execWithClosedStdin routes
no-input commands through it. The connect probe, loopback route probe,
cat download, Windows no-stdin commands, remote folder browse, SSH
automation prechecks, and execCommand without stdin all use it.

Fixes #38636

Co-authored-by: Neil <neil@stably.ai>
2026-11-15 23:47:08 -08:00
Neil e075db6f19 refactor: group shared runtime and computer owners (#42972)
* refactor: group shared runtime and computer owners

* refactor: follow computer owners in workflow triggers

* test: account for unmasked existing title-test clock call
2026-11-15 23:46:34 -08:00
Neil 1abca4eb1a fix(browser): wait for goto's navigation when the outgoing page settles loadURL early (#43013)
Electron can settle loadURL on the outgoing document's own events: a
beforeunload replaceState (vue-router 4 saves scroll this way, as on a
GitLab project home page) or the old page finishing its load. goto then
returned and notified the renderer with the previous URL, and the
renderer navigated the tab back to it.

When the requested URL has not committed and a main-frame navigation is
still pending, goto now waits for the committed main document's
did-finish-load (subframes ignored), the same point a normal load
returns. Reaching the deadline on that path reports the current page
instead of failing; the aborted-navigation path keeps its timeout error.

Fixes #42983
2026-11-15 23:36:52 -08:00
OrcaWinandOrcaWin 3014bdaa5f test: remove six low-value suites and trim parser coverage (#43014)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-15 23:30:47 -08:00
Brennan Benson 804d418384 test(browser): wait for freed offscreen page's destroyed event (#43010) 2026-11-15 23:29:21 -08:00
Brennan Benson 8feab8456e feat(uninstall): remove Orca's hooks, CLI and services from Settings → Advanced and orca uninstall (#42889)
* feat(uninstall): add the uninstall cleanup contract shared by main and the settings UI

* feat(uninstall): remove Orca's OpenCode and Pi plugin files, also from the Windows uninstaller

Only files carrying Orca's marker are removed; OpenCode 1.x's TUI registration entry goes with them.

* feat(uninstall): main-process plan, steps and finish actions for Uninstall Orca

getPlan lists agent hooks, the orca command, orca serve units, ~/.orca/agent-hooks and SSH hosts
without changing anything; runStep removes one part and returns the updated plan.

* feat(cli): add orca uninstall, sharing the app's cleanup

* feat(uninstall): add the Uninstall Orca section to Settings → Advanced

* fix(uninstall): narrow plan agent ids with isTuiAgent instead of a cast

* fix(uninstall): show home-relative paths in the uninstall plan

* fix(uninstall): bound the SSH host sub-list with useBoundedHostRows

* fix(uninstall): async fs on the main thread and no type assertions in the cleanup

* fix(cli): bundle the uninstall cleanup modules the orca uninstall command loads

* fix(packaging): unpack the uninstall cleanup entries the packaged CLI loads

* fix(uninstall): call the orca command row the CLI on your PATH

* fix(uninstall): show hook scripts under the agents' hooks row

* fix(uninstall): remove hook scripts after the last agent retry and never show kept items as done

* fix(cli): give orca uninstall and agent hooks an app environment, and exit 1 on unfinished entries

Claude's remover resolves profile homes through it; without one the CLI reported Claude failed.

* fix(uninstall): drop Muse's Orca env-var allowlist and Claude's agent-view marker

Muse keeps names the user added. The agent-view marker only remembers opt-outs for a re-enable.

* fix(cli): bundle and unpack the node service environment orca uninstall loads

* fix(uninstall): settle the agent-view disable before deleting its marker, and report ok:false on unfinished --json runs
2026-11-15 23:29:03 -08:00
Neil 78c28ab1d0 feat: discover community language packs in settings and onboarding (#42857)
* feat(languages): discover and switch community language packs

Show community translations where people choose a language: in the
Settings language dropdown (with a link to the translations catalog), a
single-list language picker that pins the device-matching translation,
a Language button in onboarding, and a one-time quiet suggestion toast.
Switching back to the previous language is always available in English.

* style: format language browser imports

* fix(languages): keep the offer action hook compilable by React Compiler

* test(e2e): drive language catalog retry through the new picker
2026-11-15 23:17:46 -08:00
OrcaWinandOrcaWin 1bea9ade72 test: remove 15 low-value suites and trim 11 others (#43006)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-15 23:14:43 -08:00
Brennan Benson d4f90c64b3 fix(terminal): restore panes in their last shell folder (#42974)
* fix(terminal): report current folder at shell prompts

* fix(terminal): preserve literal percent escapes in PowerShell folders

* fix(terminal): keep cwd hook out of Bash foreground lifecycle

* fix(terminal): keep Windows cwd reports native and unambiguous

* fix(terminal): preserve UNC cwd paths through renderer parsing

* fix(terminal): normalize Windows device drive cwd spellings

* test(terminal): require canonical cwd URI from PowerShell prompts
2026-11-15 23:01:36 -08:00
OrcaWinandOrcaWin 4aacd00b04 test: remove 14 low-value suites and trim 15 others (#42999)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-15 22:57:43 -08:00
Wooseong KimandNeil 6b88f592a8 fix(runtime): stop re-awaiting timed-out provider visible snapshots (#16560)
When a visible terminal read waits 750ms for a provider frame and times
out, hold the per-PTY visible retry gate shut while that capture is still
pending, so later visible reads return the fallback at once instead of
rejoining the same slow request. When the late frame lands in the same
PTY generation, adopt it into the visible-state cache (or re-arm the
normal backoff if it is null or stale).

The shared provider acquisition is not retired, so headless re-seeds,
restore/serialize callers, and mobile authoritative reads keep waiting
on a slow but healthy capture as before.

Fixes #16531

Co-authored-by: Neil <neil@stably.ai>
2026-11-15 22:45:55 -08:00
buf0-bot[bot] 2869f0f520 Update README downloads badge (#42996)
Co-authored-by: buf0-bot[bot] <252831055+buf0-bot[bot]@users.noreply.github.com>
2026-11-16 06:42:17 +00:00
OrcaWinandOrcaWin 6ceacf927f test: remove 11 low-value suites and trim 17 others (#42989)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-15 22:39:11 -08:00
Kelvin Amoaba a2d17f8208 fix(native-chat): Skip and agent messages agree with the Codex question card (#42946)
* fix(native-chat): make Skip and agent messages agree with the async question card

Skip on a Codex async question card now saves the skipped row on the chat's host
record (agentSession.skipAsyncQuestions, modelled on cancelUsageLimitContinue), so
the status, the desktop card and the phone card all honour it. The host status read
no longer ends at another agent's message, matching the card's rule from #35758;
two partial indexes, created without a schema version bump, keep that read bounded.

* fix(native-chat): gate phone Skip on relay support; roll back only its own hide
2026-11-16 06:36:09 +00:00
Brennan Benson 5ff527c30b perf(worktrees): patch heads on HEAD-only watcher bursts instead of re-listing (#42941)
* perf(worktrees): patch heads on HEAD-only watcher bursts instead of re-listing

* fix(worktrees): fall back to re-list for headless or absorbed HEAD moves

* test(worktrees): cover orphan HEAD re-list fallback

* fix(worktrees): keep orphan fallback through merged scopes and patch hidden rows

* fix(worktrees): guard hidden-row head patches against stale listings and other hosts

* chore(worktrees): read detected rows through the selector; document test window cast

* chore(worktrees): read detected rows only through the selector

* fix(worktrees): skip the concurrent-head guard when no patch landed; keep pinned names on reattach
2026-11-15 22:31:48 -08:00
Brennan Benson 84f1c520a8 Keep one copy of Codex history shared by every account (#42614)
* Share Codex account history through folder links into ~/.codex

Each Codex account home keeps its login; its history folders become folder
links (junctions on Windows) into the user's ~/.codex, and Codex's databases
follow through a sqlite_home line in the account's own config. Migration is
automatic before the next launch in each home; the store's copy wins a name
conflict and the account's copy is kept beside it. The per-file history bridge,
its link pass and the WSL bridge are removed. Claude's merge-then-link moves to
a shared async module both providers use.

* Make account history moves safe under concurrency and keep the DB with the folders

Files move by link-then-unlink so a move never replaces an existing name, host
passes run one at a time per store, index markers are written before a move,
account-only folders are shared, lock folders are moved rather than deleted,
and sqlite_home is written only once a home's sessions are linked.

* Let the history pass own sqlite_home, link locks first, and index per store

The pass that links a home's folders now writes and removes its sqlite_home
line; the config mirror only carries it forward. thread-writer-locks is linked
before any history, index markers are kept once per store (hard-linked
duplicates included), WSL links the launched home before Codex starts, passes
queue per home in request order, and re-sharing after off then on works with
earlier conflicts still kept.

* Never overwrite on move, gate indexing on moves, and read the shared DB for backfill

Files move by link or exclusive copy; repeat conflicts get their own pending folder; secrets and
sandbox setup stay per home; the sqlite_home write retries against a concurrent mirror; indexing
waits until no move is running; backfill checks read the DB where sqlite_home puts it.

* Keep live writers' files, require both history links, and keep unmoved history on removal

Files move only by a new name for their inode; a home is shared only when sessions and
archived_sessions both link; reverted-thread rollouts get index markers; settled homes skip
repeat passes in either mode; account removal keeps a real history folder.

* Give resume test runtime-home mocks the account history step

* Keep unmoved WSL history on removal, prepare the launched home, and retry incomplete work

WSL account removal keeps real sessions/archived_sessions; a launch prepares the account it
returns even if the selection changed meanwhile; an incomplete unshare and a failed WSL index
pass stay eligible for a later launch; the guest helper rechecks the distro before each step.

* Keep pinned resumes reachable, finish interrupted unshares, and keep index work from racing moves

A pinned resume only shares; a launch re-prepares when the selection or setting changed; Orca's
sqlite_home line is read only at the config root; a writer-lock link elsewhere keeps the home
private; an unshare finishes its database move on retry; indexing keeps markers a newer move
recorded, retries an incomplete run on a later launch, and merges WSL marker lists.

* Move account history into a store one pass at a time and retry incomplete moves

Two homes merging into one store at once raced on its folders and stranded the second home's
history in its merge folder. Passes now run one at a time per store (host) and per distro (WSL),
a folder that appears mid-move is merged into, and a share with failed moves is not settled.

* Keep one rollout form in ~/.codex, record what sharing left behind, and guard Windows homes from older builds

- A rollout present as .jsonl and .jsonl.zst lands in the store in one form only; the other form moves to the home's .orca-set-aside-rollouts, never deleted.
- Each account home gets a versioned cleanup manifest: set-aside databases, left-behind rollouts with a background content check against the store, store twin pairs, and the shared streak.
- Native Windows homes get a renamed ownership marker before their first junction, so older builds refuse to use or delete them.
- Account removal keeps the set-aside rollouts and the manifest.

* Set a rollout form aside only beside its twin in the store, inventory leftovers off the launch path, and keep account databases on removal

- The .zst moves first and a form is kept out only when the store already holds its twin, so a failed move never leaves the store with neither form.
- The rollout inventory and store twin walk run in the detached check, not the awaited pass; manifest writes are serialized per home and a check applies only to unchanged files; checkpoints are time-spaced.
- A WSL check that runs out of budget resumes on a later launch instead of looping.
- The ownership check reads either marker in one step and the marker rename retries on Windows.
- Account removal keeps the account's Codex databases for the later cleanup release.

* Read the cleanup manifest through a type guard

* Read the cleanup manifest through a type guard over unknown

* Settle only a check's own request, skip queued WSL passes after quit, and validate manifest entries

- A pass finishing during a check keeps its new check request on host and WSL.
- A WSL pass queued before quit no longer starts guest work.
- Manifest rollouts must carry a path, size and mtime to be read.
- The store twin scan reuses the twin module's folder walk.

* Walk the store outside the manifest write and keep databases on removal only for shared homes

- The inventory writes only its own fields onto a freshly read manifest, so it never undoes a streak reset from another process and a launch never waits behind the walk.
- Account removal keeps the home's Codex databases only when the cleanup manifest shows the home was shared.

* Lock the cleanup manifest across processes and validate every field later passes read

- Manifest writes take a file lock, so a WSL check helper can't publish over another helper's streak reset.
- The guard also checks storePath, the content check's store facts, database entries and sharedPasses; anything else is rebuilt from disk.
2026-11-15 22:31:24 -08:00
Brennan Benson dc50f873ca Keep a slept workspace asleep when Orca relaunches (#42944)
* fix(sleep): keep a workspace asleep at quit from being reopened on relaunch

* fix(sleep): don't treat running agents' resume records as sleep in the startup fallback

* fix(sleep): keep the startup fallback unchanged for sessions saved without a shutdown list

* chore: prune workspace record read baseline

* style: format
2026-11-15 22:29:37 -08:00
3c1f02cf8c Rebuild phone snapshots only for workspaces whose inputs changed (#42934)
* Remove finished-agent retention and keep sleeping status with panes

* Fix legacy pane projection and sleeping-agent regression fixtures

* Cover sleeping display-only status in parked terminal coverage

* Keep pane conversation identity only across continuous agent observations

* Remove duplicate import and keep sleep fixtures type checked

* Preserve conversation boundaries across replays and inherited clocks

* Cover conversation map stability across a large status batch

* Bound conversation capacity work to changed pane owners

* Pass capacity classifiers their layout input directly

* Finalize conversation provenance once per status batch

* Keep paired snapshot tests focused on observable outcomes

* Type the conversation provenance test fixtures explicitly

* Consolidate agent session imports after main merge

* Preserve provider replacement evidence when resetting conversation continuity

* Separate retention deletion from sleeping agent display

* Restore migration row bucket comparison

* Skip unusable pane identities before title ownership lookups

* Refresh conversation titles when their owning pane changes

* Update completion test sound mock after module move

* Keep finished agent status with sleeping panes and update agents by key

* Forward sleeping pane status and scope paired tab updates

* Preserve keyed selectors and compiler invalidation through final checks

* Keep bound store hooks visible to the compiler and measure published links

* Install provenance measurement before factory capture

* Use a static store hook and name presentation metadata once

* Preserve keyed freshness and atomic agent status publication

* Preserve remote folder dashboard regression after suite retirement

* Model pane wake before live identity reobservation in regression

* Share keyed row transactions and finish main integration

* Align runtime fixtures with keyed agent status reads

* Keep status projections addressed and activity summaries current

* Retire empty workspace status summaries after their source leaves

* Use the standard store fixture for parked terminal graph tests

* Align status fixtures with app types and a fixed test clock

* test: capture stored terminal render failure details

* Read terminal titles and completion prompts from keyed agent status

* Compose foreground agent state in worktree test stores

* test: complete lineage list agent state fixture

* Keep sleeping completion when retiring process authority

* Run durable agent-hook status tests with Node SQLite

* Preserve sleeping Done when renderer retires its process

* Update terminal fixtures for process retirement

* Spike addressed renderer agent status publication

* Join status only against admitted mobile membership

* Scope status membership reconciliation and observe bindings by key

* Cover status admission and scoped replica recovery

* Name the status replica runtime owner type

* Read sleeping pane resume sources by key

* Bind sleep capture fixture to its live panes

* Bound status replica retirement and recover interrupted publication

* Pass the pane tree to the sleep capture fixture graph

* fix(status): skip non-UUID leaves, release phone frames on headless restore, avoid unbound tree scan

- Graph status bindings and replica membership skip leaves that can't carry a status row instead of throwing.
- The pre-seed phone gate only holds frames for the renderer generation that owes the seed; restoring headless authority redelivers the held worktrees.
- Status capture skips the leaf count when the tab has no terminal, and counts saved leaves only up to two.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* fix(status): release held phone frames whenever the unseeded renderer loses the graph

Desktop builds without a headless fallback mark the graph unavailable but keep the renderer generation, so the pre-seed gate stayed shut until a window reopened.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* perf(status): reuse the capped saved-leaf count per immutable layout

Status churn on an unmounted tab with only a tab-level terminal no longer descends a deep saved split tree on every change.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* Preserve accepted completion identity through sleep

* Pass a nullable title to the status classifier

* Resolve accepted host status once and preserve delivery order

* Drop published sleep status when its host owner retires

* Use the supported remote completion test envelope

* Preserve published activity when filling completed status

* Update imports for main module moves

* Remove an unreachable native chat owner comparison

* Read host and unread card inputs by address instead of per root

A host-scoped sidebar card re-read every root's row and acknowledgement on
any store write, so one card with many sleeping roots paid for other
workspaces' updates. Card host filtering, the summary pill's unread state
and the workspace unread gate now first compare the workspace's projected
row revision and the changed keys of the tab-keyed layout/PTY maps and
the acknowledgement record. Only an addressed change re-reads the roots.
Acknowledge and unacknowledge annotate their writes so readers can skip
keys they don't show.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* Correct sleeping pane test imports after module moves

* Combine duplicate subscription test imports

* Record addressed acknowledgement deletions on row drops

* Type subscription fixture key set for string readers

* Keep accepted updates complete after observer failures

* Seed the send picker with its SSH terminal identity

* Correct status publication imports after preload module move

* perf(layout): skip unused normalization reports in pane commands (#42615)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Clarify cleanup pinning and ignored-file protection (#42616)

* test: remove 55 low-value suites and assertion driver (#42605)

Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>

* fix(skills): skip Claude sync scratch folders during skill discovery (#42610)

Claude Code parks replaced skill copies in `.trash` and in-progress syncs
in `.staging` under its skills roots. Discovery walked into both, so each
synced skill showed up as duplicates. Prune those directory names in the
native file walk and in the generated WSL `find` command.

Co-authored-by: Neil <4138956+nwparker@users.noreply.github.com>

* test: remove 78 low-value suites and trim redundant cases (#42621)

Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>

* Keep a host card's unchanged agent rows after filtering out another host's pane

Re-lineage clones every row once a host-scoped card filters a row out, so an unrelated pane's status write rebuilt the card's row array and re-ran its signal and rollup memos. Reuse unchanged rows as main's sidebar row selector does.

* Document the runtime stub cast in the status admission test

* Await graph publication in the phone projection status tests

* Share the renderer status binding check and move graph tab-id validation out of the window graph

Main's async graph publication grew session-window-graph past the 300-line limit; the binding predicate now has one owner beside its capture path.

* Seed the Copy Session ID shortcut test through keyed agent status

* Restore the reviewed status binding checks and move the remount check instead

Keeps the capture path's lookup behind its UUID and changed-worktree guards; the window graph stays under the line limit by moving the PTY remount check to the graph promotion base.

* Seed the graph payload partition test through keyed agent status

* fix(agent-status): retry status publication after a failed or superseded graph sync

An inactive sender now asks for a graph sync on each status change (base got this
retry from agentStatusEpoch in the sync key), and a superseded ack parks the sender
until the next accepted graph instead of stopping it.

* fix(agent-status): don't stage status changes while a snapshot is pending

A parked sender kept tombstones for every removed occupant; the next snapshot
recaptures every row and main clears its replica on snapshot.

* fix(agent-status): don't start renderer status publication in paired web clients

The web stub answers every batch with superseded; with superseded now re-arming
on each accepted graph, a web sender would resend snapshots and request graph
syncs for nothing.

* Rebuild phone snapshots only for workspaces whose inputs changed

Every runtime graph publication built per-workspace phone snapshot inputs
(owner resolution, narrowed maps, mounted-surface capture) for every retained
workspace before asking whether the cached snapshot could be reused. A gate
now runs first: a workspace reuses its snapshot without building inputs when
no shared input changed, no keyed write touched its tabs, it has no mounted
terminal, its own workspace-keyed sources are identical and its host tab
mapping revision is unchanged. Anything without keyed provenance falls back
to the previous full path. The ambiguous-tab-id set and the per-workspace tab
index are cached by their tabsByWorktree identity.

* Remove the now-unused single host tab mapping setter

---------

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-authored-by: Jinjing <6427696+AmethystLiang@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: OrcaWin <alpha-eng@stably.ai>
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
Co-authored-by: BingZ <zzb@gxsmjx.com>
Co-authored-by: Neil <4138956+nwparker@users.noreply.github.com>
2026-11-15 22:29:21 -08:00
Neil 05badcb087 test: remove one flaky queued-hold case, steady the Claude stop-contract fixture (#42980)
* test: remove a flaky queued-hold wire-contract case

It failed intermittently under CI load: its closing history read raced the journal's SQL reader
closing. It also reads private host state through collaboratorsForTests() and waits on real time,
both listed in docs/agents-md-refs/test-antipatterns.md.

* test: give the Claude stop-contract fixture's attach wait the same 10s as its actions

Under a loaded CI runner attach outlasted vi.waitFor's 1s default, so the compact-background test
failed with "expected 'starting' to be 'ready'" before reaching what it checks.
2026-11-15 22:22:37 -08:00
OrcaWinandOrcaWin 19aa1251dd test: remove 20 low-value suites and trim six others (#42978)
Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-11-15 22:15:36 -08:00
Kelvin Amoaba 4505f20e58 fix(mobile): make chat report buttons work in an isolated frame (#42954)
* fix(mobile): run chat report scripts in an isolated shell frame

* fix(mobile): theme chat visuals at handoff and pin the iOS frame to Android's

* test(mobile): probe the page origin by absolute URL from the visual
2026-11-16 06:13:52 +00:00
Kelvin Amoaba f375aba997 fix(mobile): make chat report buttons work in an isolated frame (#42954)
* fix(mobile): run chat report scripts in an isolated shell frame

* fix(mobile): theme chat visuals at handoff and pin the iOS frame to Android's

* test(mobile): probe the page origin by absolute URL from the visual
2026-11-16 06:12:04 +00:00
Kelvin Amoabaandintelmib 0af8a7e427 fix(source-control): offer Amp and Muse only for chat names, with an honest refusal elsewhere (#42923)
* fix(source-control): stop offering Amp and Muse for non-naming AI text

Amp and Muse can't take the read-only text task policy, so the policy refuses
them for everything but chat naming. The picker and the operation resolver
still offered them, and the refusal surfaced as "could not be started".
Keep the naming-only fact in the shared agent spec module and use it in the
resolver, every agent list for these actions, and the policy backstop.

* fix(source-control): keep recipe args before the prompt terminator

Muse ends its argv with `-- <prompt>`, so recipe args such as --model were
inserted after `--` and became prompt text.

Co-authored-by: intelmib <intelmib@gmail.com>

---------

Co-authored-by: intelmib <intelmib@gmail.com>
2026-11-16 06:07:30 +00:00
Neil b4878a5eae feat(plugins): clearer update review, approve from the toast, grouped approvals (#42953)
* fix(plugins): show only what an update adds in its review

The update review compared Before and After columns that mostly repeated what the user had already
approved, and labelled new custom editors, hooks, settings pages and status bar items with the
vague "Features that act for you". It now lists just the additions, naming each one (a new editor
names the file types it opens), and says so plainly when Orca couldn't compare the versions,
opening the full access list.

* fix(plugins): keep a failed comparison and every grant visible in the update review

- Says Orca couldn't compare whenever main sent no comparison, even when the source also moved, and
  opens the full access list then.
- Lists every new grant main asks about, not only the ones this plugin type can use.
- Names editor growth per editor id: new file types, files it now opens by default, else a generic
  line; waits for the installed manifest so the line doesn't change under the reader.
- "Adds panels" and "Reacts to more Orca events" replace "Panels" and "More events".

* feat(plugins): approve held updates from the toast, open the review anywhere, group approvals

- The review and the toast name each plugin's publisher ("Official · stablyai", "Community · …").
- The held-update toast lists each plugin with what it adds and the not-official warning when one
  applies, and approves in place when every update was compared and can install; otherwise, or
  for more than three plugins, "Details" opens the review.
- The review opens over the app instead of sending the user to Settings → Plugins.
- Several updates that need approval are one grouped review with a checkbox each and one
  "Approve & update", instead of a separate Review per plugin.

* fix(plugins): offer approval only once every addition is shown, keep late notices

- The toast and the review read the installed manifest with the preview, so "Approve & update"
  exists only once every line it approves is on screen; the toast also needs the installed entry.
- A notice that arrives while the toast installs stays on screen; a newer version of a plugin
  reloads its details instead of showing the old ones.
- Retrying in the toast skips the updates that already landed; an update whose bytes changed
  after review says it waits in Settings → Plugins instead of reporting success.
- In "Update all…", approvals beside plain updates start unticked; the not-official warning sits
  under its plugin's name and names the catalog owner.
- The toast e2e covers Details and approving in place.

* fix(plugins): a compact community badge and a history link in the update review

- "Community plugin · owner" with the warning icon replaces the not-official banner in the review
  and the toast; the trust advice shows on hover or focus.
- The version text links to the plugin's history on GitHub at the reviewed commit, and a moved
  repository is one short line instead of two URLs.

* refactor(plugins): share update loading and installing, keep the toast out of the store

- One loadUpdate and one installUpdates serve the review and the toast; both now say when an
  update's bytes changed after review.
- The notice store holds data only; PluginUpdateReviewHost renders the toast and the dialog.
- The update lines users approve are protected copy; the version link sits outside the checkbox
  label; a community plugin that runs no code gets the same "Community plugin" label, unmarked.
- Tests for notice merging and for approving only the reviewed fingerprint.

* fix(plugins): a warning Badge variant for the community badge; tests without casts
2026-11-15 22:05:03 -08:00
4f6a788951 fix(wsl-host): prune removed projects from the saved host catalog snapshot (#42150)
Removing a project on a WSL host left it in that host's saved repo.list
snapshot, so a restart while the distro was stopped re-seeded the removed
project into the sidebar. The repos:removeForHost handler now drops the
project from that host's snapshot after removing the row. Damaged or
missing snapshot entries are left untouched.

Co-authored-by: Neil <neil@stably.ai>
Co-authored-by: SeaBee <temp@seabee.me>
2026-11-15 22:04:45 -08:00
Hotragn Pettugani b3d1666118 fix(bitbucket): list commit statuses from the statuses endpoint (#42970)
GET .../commit/{sha}/statuses/build returns 405; only POST and GET with a key
exist there. Listing is GET .../commit/{sha}/statuses, so PR CI status was
always empty.

Fixes #42969
2026-11-15 21:59:33 -08:00