Skip to content

merge: sync pinned upstream ae0ff6315219 into fork-main - #27

Merged
karlorz merged 78 commits into
fork-mainfrom
sync/upstream-2026-10-12b
Oct 12, 2026
Merged

karlorz merged 78 commits into
fork-mainfrom
sync/upstream-2026-10-12b

Conversation

@karlorz

@karlorz karlorz commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

ELI5

Bring the fork up to the pinned upstream version while preserving the fork's updates, voice features, Linux folder browsing and release safeguards.

What Changed

Merge upstream ae0ff6315219fa0492bd2e874954f992bc859694 into fork base 18b802146346a70d80d931730e405dd60c7af781 with a two-parent merge on sync/upstream-2026-10-12b. The pinned graph contains 74 upstream commits and about 1,539 changed files.

Users receive upstream fixes and the build-commit-pinned skill install/update rail. Fork skill installs continue using karlorz/orca; Linux folder selection continues using the in-app browser; live dictation retains insert/replace behavior through upstream's transport-owned paste route. Resolve 22 conflicted files and retain the fork's changed-spec CI shards alongside upstream managed-SSH exclusions and artifact naming.

The packaged macOS terminal diagnostics, exact-head publication-disabled signing wrapper, shared packager, original computed PTY/signature gates, home AppImage installer and protocol-gated updater policy remain preserved. Full pins, decisions and local evidence are in docs/audits/SYNC-NOTES-2026-10-12b.md.

Why

An ancestry-preserving merge keeps the upstream relationship explicit for later syncs and limits custom resolutions to fork-owned behavior. Runtime-launcher changes retain daemon protocol 45: the exact-base R3 ratchet passes and needs no override label.

Linked Issue

Authorized maintainer fork synchronization. No separate issue was opened.

Visual Proof

N/A — this integration preserves fork UI behavior and imports upstream changes. Live GUI validation is held by the task's execution scope; automated renderer fixtures and ordinary isolated-display CI supply regression checks.

Testing

  • I manually tested these changes locally (offline commands and fixtures; Linux).
  • Automated tests added/updated, or explained why not below.

Root and mobile frozen installs passed with lifecycle scripts disabled; process-host built. Heavy checks use the shared flock, >=2 GiB available-memory admission inside the lock, heavy-run, one Vitest worker and background-launch mode.

  • Initial broad offline fork/updater/skill/ratchet batch: 941 passed, 53 skipped, two inventory source-fixture failures. Fork ownership fixtures corrected.
  • Focused resolution, renderer, inventory, daemon-init and packaged diagnostic rerun: 167 passed, one explicitly excluded real-native-PTY test.
  • Shared regression batch: 25 passed. Changed mobile pairing/stream/refit plus fork APK updater and speech batch: 133 passed.
  • R3 runtime-launcher/protocol check against the exact fork base: passed (45 -> 45).
  • Final key merge regressions: 155/155 passed. CLI typecheck passed.
  • Root, casting and focused changed-code scans: zero new findings across 1,122 code files. The type-aware scan was stopped at approximately 4 GiB RSS to protect the shared host; full local quality remains unverified. Initial CI root/native/type-aware lint reported zero errors before renderer typecheck failed.
  • Initial CI compiler comparison, PR static/typecheck and Windows packaged build found a shared-browser prop mismatch. Normal same-branch repair 7c0ffb6f86aac3c8a8d38d96b90c73e5b6f027e8 restores SSH target forwarding for the project-location caller; 16/16 browser regressions passed, including explicit existing-folder and clone target assertions.
  • Browser-repair head passed compiler comparison, static/typecheck, Linux and Windows packaging, changed-spec/layout checks, managed SSH, mobile bundle and wire compatibility. Its five unit shards isolated 16 skill-source assertions across seven files. Same-branch fixture repair uses the fork source and adds upstream foreign-source no-nudge/presence checks: 86/86 tests passed in eight Node suites; scoped lint and formatting passed. Local Bun could not load the glibc rolldown addon because its binary uses musl; CI covers that runtime.
  • Final offline safeguard batch: 89 passed, 3 explicit skips after generating missing mobile WebView prerequisites. Narrow type-aware browser lint passed; whole-file design lint flags six inherited primitive restyles.
  • Broader offline skills: 878 passed, 43 skipped; eight-file narrow type-aware lint passed. Whole-file casting lint flags 12 inherited assertion lines; changed-line CI gate remains authoritative.
  • Mobile verify at the next head passed 10,335 assertions but failed on an unhandled bridge retry after test-environment teardown. The fixture now owns fake timers and clears retries before restoring globals, with bounded retry and late-bridge delivery assertions. Nine terminal document suites passed 69/69 tests; scoped mobile lint/format passed. Production behavior remains intact.
  • Full local Node mobile run at ed5bd45552be7ca1458fb088e561d4a28dfd1897: 10,809 passed, six skipped, zero unhandled errors; five suites could not collect because the script-free install omitted generated rich-Markdown and Mermaid bundles. The ordinary CI mobile verify passed at this head.
  • Scoped formatting and diff whitespace checks passed. Exact-head CI at ed5bd45552be7ca1458fb088e561d4a28dfd1897 is green: 73 successful checks and 11 intentional skips, including mobile Bun verification and all five unit shards. The PR is open and mergeable. Coordinator accepted both repairs and received the merge-ready report.

Published upstream mobile train 0.0.52 confirmed; fork release mobile-android-v0.0.52-3 already supplies the APK. Marketing version remains 0.0.52, versionCode 86.

Limitations: script-free install has no rebuilt PTY native binding; no actual signed macOS, Rosetta, arm64, Windows or SSH-host execution occurred locally. Signing validation, release/tag, deployment and live installed-app validation require the coordinator's separate approval.

AI Disclosure

Implemented and locally reviewed with an AI coding assistant in the assigned isolated checkout. No nested agents were launched. The coordinator owns independent review and final integration.

Review

Self-reviewed conflict resolutions, fork feature inventory, mobile APK evidence, unchanged diagnostic/signing/install guards and protocol compatibility. Independent coordinator review remains pending.

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

This authorized upstream merge includes upstream skill-installer changes and fixtures. The install/update source and ownership checks remain fork-owned.

Notes

All product execution hosts, folder workspaces, cross-platform paths and independently updated peers remain relevant. Existing fork capabilities and pet speech execution-host routing are retained. This PR remains open for parent review; merge, signing, release and deployment execution remain held.

Checklist

  • This PR is small and focused (one pinned upstream sync; large upstream diff).
  • I explained what changed and why (ELI5, user experience, mechanism and approach).
  • Before/after screenshots or videos attached for UI changes, or N/A with reason.
  • Self-reviewed for correctness, security, and performance.
  • Cross-platform, SSH/remote, and path/shortcut impact considered.
  • Ordinary PR CI lint, typecheck, test and build checks passed at the exact final head; local limitations are listed above.

OrcaWin and others added 30 commits October 11, 2026 13:42
Panes stopped spawning on unconverted ssh: rows in stablyai#27489, so the retry,
live-binding and history ledgers were written but never read. Delete them,
the retry and settle actions, and the detach transfer. The disconnect and
new-authority clears keep nulling stale ssh: PTY ids exactly as before.

Co-authored-by: m4air <[email protected]>
* chore(relay): move the staging cells onto image F

Staging c1, c2 and c4-c7 run image F (main 3c1141f), so the director and
every staging cell share one digest for the c5-c7 promotion and the
six-cell dead-cell rerun. c3 is unchanged.

* test(relay): pin the staging C4 digest to image F
Paste and drop planning no longer re-derive an SSH connection from the
worktree. After C1 no pane transport carries a relay connection, so the
'ssh' paste kind, the worktree fallback and terminal-paste-ssh-platform.ts
are gone.

Co-authored-by: m4air <[email protected]>
… not a pairing offer (stablyai#27533)

Desktop, CLI, web and runtime transports now take a PairedRuntimeConnection
(endpoint, pinned host key, credential) instead of a PairingOffer. Offers stay on
the pairing input path (codes, QR, links, environment add) and are converted with
pairedRuntimeConnectionFromOffer. The credential is token-only today; request
envelopes still carry the same deviceToken, so the wire is unchanged.

This lets device-key and ticket credentials replace the token later without
touching every connect call site again.

Co-authored-by: m4air <[email protected]>
…lper (stablyai#26771)

* Keep browser tabs in place when the + button opens a terminal

The + new-terminal path kept its own copy of the tab-order placement and
left browser tabs out, so in a workspace with no saved order a browser tab
could land after the new terminal. Use the shared persistAgentLaunchTabOrder
helper instead.

* Use the shared tab-order helper for the remaining new-terminal paths

handleNewTab's shell-override fallback and the menu new-terminal IPC
fallback each kept an inline copy of the "put the new tab last" order
logic. Both now call persistAgentLaunchTabOrder. The one behaviour
difference: the shared reconcile drops ids repeated in a saved order,
where the copies kept them.

* Drop unchecked casts from the new tab-order tests
…ai#26489) (stablyai#27173)

stablyai#26489 started no-prompt "+" launches through the host lane that is built for
terminals no window shows, into a pane the window already owns. That lane
differs from the window lane in start size, env, telemetry, failure handling
and Windows runtime resolution. Restore main's window route until the two
terminal lanes are converged, then move "+" onto the single lane.

This reverts commit 7634bbf.
* test(e2e): read the live runtime layout in the layout oracle

The oracle now reads the runtime's layout from a layout.subscribe consumer
(the window's renderer, or a headless host's pairing offer) instead of
session:get or the saved profile. Model rules run on every published frame,
replacing the 300 ms settle read and the 100 ms rule sampler; disk-format
rules and the round trip run on the saved profile at each settled step.
Views are compared to the live layout exactly for every group and tab kind.
The known-on-main list is refilled from runs of this oracle on main.

* test(e2e): known-on-main differences do not hold the oracle's settle wait

A difference main is known to keep never converges, so a step settles once
only known-on-main differences remain. The orcad title-after-restart entry
is narrowed to the scenario a run on main reproduced.

* test(e2e): oracle settle counts frames across sleeps, pairs renamed groups, flushes saves

The settle wait carries the frame count across reads, so a frame during the
sleep restarts the quiet window. The client check pairs a group listed under
another id with the runtime group holding the same tabs in the same order,
so only that rename is known on main and a dropped group still fails. The
window flushes main's debounced save before the saved-profile read.

* test(e2e): refill known-on-main from Linux CI and post-flush runs on main

Removes the two-writers saved-profile entry (gone once the window flushes
main's save). Re-adds client-reorder tab order and the cold-relaunch client
list, and adds the cold- and live-daemon relaunch tab-bar entries and the
Electron rename-after-restart entry, each reproduced by Linux CI run
38170663248 or a local run on main's code.

* test(e2e): scope known-on-main entries to the OS that reproduced them

Entries reproduced on one OS only carry a platform and match only there.
The cold-relaunch restart entry now matches only a single group whose tabs
and order are unchanged, so a reorder still fails.
…n tests (stablyai#26819)

Command-, route-, version- and host-shaped text stays plain unless the
host confirms the path, in chat and terminal alike, since stablyai#26675.

Co-authored-by: Kelvin Amoaba <[email protected]>
…plain-http pages (host) (stablyai#27540)

* feat(runtime): session-only browser keys and an opt-in for pairing from plain-http pages (host)

- pairing.registerDeviceKey accepts ephemeral: true (advertised as
  pairing.device-key-ephemeral.v1). Such keyed rows are dropped when the host
  restarts and after 12 hours with no live socket; a sweep removes them and cuts
  any socket still bound to them, so later key auth gets device_revoked.
- The WebSocket upgrade Origin is recorded per socket. A first pairing (a
  never-used pairing code) from an http:// page on another machine is refused
  with a sealed insecure_origin error unless the operator sets
  ORCA_ALLOW_INSECURE_WEB_PAIRING=1. Already-paired browsers, https and loopback
  pages, and native clients are unchanged.
- Registry file reading moved to device-registry-file-read.ts to keep the
  registry under the size cap.

* fix(runtime): gate first pairings only for the marked web client, never phones

React Native sends an http Origin on every LAN WebSocket, so the Origin alone
refused first-time QR pairing from released phones. The web bundle now marks
its upgrade with ?orca-client=web; only a marked socket from an http page on
another machine is gated. Released hosts ignore the query string.

---------

Co-authored-by: m4air <[email protected]>
…rdinator (stablyai#27587)

No ssh: git provider is registered in production, so the reconnect
coordinator's catalog and lineage reads always came back non-authoritative
and its worktree refresh never merged. Its only live effect was clearing an
unconverted target's stale PTY bindings on each connected push and on wake;
the state bridge now does that directly.

Deletes the coordinator, preparation, worktree refresh scheduler, host
hydration, rollout flag and their product telemetry event, the scoped
direct-SSH reconnect/hydration options, and the now caller-less
repos:listForExecutionHost and worktrees:listLineageForHost IPC handlers.

Co-authored-by: m4air <[email protected]>
…or native chat (stablyai#27593)

* refactor(renderer): no client SSH operation arms in project creation or native chat

* fix(add-project): show the start step when the remote step loses its server

---------

Co-authored-by: m4air <[email protected]>
…nection (stablyai#27601)

* test(e2e): open the oracle's headless layout stream with a paired connection

The remote subscription now takes a paired connection rather than a pairing
offer; build one from the offer the way the CLI does.

* test(e2e): build the paired mobile client's connection from its offer

Same stale call as the oracle stream after the subscription and request
functions took a paired connection.
…k was in the background (stablyai#27167)

* fix(native-chat): offer restart resume for chats whose only work was background

The quit started the chat teardown and then stopped the hook server, which
emptied the status store holding each chat's subagents and background
commands. The teardown reads that store to decide which chats were still
working, so a chat whose turn had finished but whose background command or
subagent was still running was never offered to resume after a restart or
update. The quit now stops hook ingress without clearing the store.

* test: preserve background-only chat resume across shutdown
… pairs for this session only (stablyai#27552)

* feat(web): the browser signs in with a non-extractable device key, or pairs for this session only

- On a secure page with WebCrypto Ed25519, the browser registers a non-extractable key
  (stored in IndexedDB, create-exclusive across tabs) over a v2 token socket, then
  reconnects with key auth and replaces its stored pairing code with a placeholder.
  Requests on a keyed socket carry no token.
- On a plain-http page on another machine, or without Ed25519, existing stored pairings
  keep working unchanged (with a warning); new pairings stay in memory and, when the host
  supports it, register a session-only key.
- Only a sealed device_revoked naming this browser's key deletes it; a downgraded host,
  a bad proof or host storage trouble keep it.
- The shared handshake core gains an async device-key credential (v2 only).

* fix(web): mark web sockets, bind keys to their pairing, survive a broken key store

- Every web socket carries ?orca-client=web so hosts gate only the web bundle.
- A key record belongs to one pairing revision: a re-pair uses its fresh code.
- A code that never migrated connects without reading IndexedDB; a migrated
  pairing whose key store fails retries instead of going dead.
- A tab that finds the key already active forgets its code, and saving a stale
  copy of the same pairing never puts the code back over a placeholder.

* fix(web): a stale tab never deletes or overwrites a newer pairing

A key record from a newer pairing revision is left alone (the tab stays on its
code), and saving an older revision never replaces a newer stored pairing.

---------

Co-authored-by: m4air <[email protected]>
…27597)

The layout oracle checks the saved profile's round trip at every settled step and the live layout's model rules on every published frame, which covers what this 1 s settle logger did.
…r's clipboard (stablyai#27605)

Orca-launched Codex on a headless runtime gets SSH_CONNECTION so Codex sends
OSC 52 to the viewing terminal instead of only the host's clipboard.

Fixes stablyai#23530

Co-authored-by: m4air <[email protected]>
* refactor(renderer): no rebound-settings owner pattern

* chore: lower focus-read baseline for composer owner scalar

---------

Co-authored-by: m4air <[email protected]>
…stablyai#27609)

* refactor(ipc): filesystem and repo handlers are local or runtime only

* test(ipc): drop two casts in the rewritten listing and import tests

* fix(providers): keep the default error name so IPC callers see the old text

---------

Co-authored-by: m4air <[email protected]>
…ry (stablyai#26690)

* fix(native-chat): preserve pending diagrams and retire reveal history

* fix(native-chat): keep diagrams through theme changes and key reveal history by message id

- MermaidBlock: a result goes stale only when its source changes, so a theme switch keeps
  the old diagram until the new one renders instead of flashing back to source.
- Reply reveals keep only loaded message ids (conversation rows plus subagent rows), since
  only message rows reveal; drops the separate row inventory and restores nativeChatSlotKey
  to the slots module.
- CommentMarkdownDocumentPre: drop the unreachable renderMermaid half of the fence check.
- Tests: Mermaid stays idle while streaming (waits past the async load), theme change keeps
  the diagram, held renders are settled after each test, a reopened subagent section does
  not replay its streaming reply through the real list, and retirement is tested by outcome.
…yai#27613)

* test(renderer): characterize all-host catalog settlement

* refactor(renderer): one default-host read; one catalog fan-out

---------

Co-authored-by: m4air <[email protected]>
…tablyai#26796)

* fix(renderer): jump instead of smooth-scrolling under reduced motion

A scripted scroll's explicit behavior ignores the reduce-motion setting.

* test(renderer): cover motionSafeScrollBehavior under reduced motion

---------

Co-authored-by: Brennan Benson <[email protected]>
* ci: the layout oracle gates merges

An oracle-only job joins verify's needs. It runs only the two layout oracle
specs through the existing e2e workflow, routed by layout writer paths; a PR
outside the route skips it and verify treats the skip as a pass. The route is
widened to the terminal store, terminal pane, graph sync, frozen mirror and
compatibility folders while the layout-holder stack is open. The oracle specs
leave the advisory e2e job so a PR does not run them twice.

* ci: the layout oracle tests the merge commit and routes its harness and stack writers

Review fixes: run on the merge commit so a stale-base PR cannot pass on an old
main; route the oracle's own e2e harness and runtime client (a change there broke
main's oracle without running it), and the window-side layout writers the stack
edits; move the route into its own module.

* ci: route the remaining layout writers the stack edits to the layout oracle
…n't freeze the window (stablyai#26987)

* feat(editor): run Nim and Typst on the shared TextMate layer with per-line limits

The editor's Nim and Typst highlighting moves from vscode-textmate onto the
Shiki core + Oniguruma layer chat uses, with the same per-line length cap and
time limit. A skipped line leaves the rest of the file plain instead of
freezing the window. Chat code block labels now name catalogue languages
(vue -> Vue, ts -> TypeScript).

* test(native-chat): expect the catalogue label for a ```ts fence
Jinwoo-H and others added 28 commits October 11, 2026 22:29
…27695)

* feat(relay): declare Asia spare cell c35 as migration-only

Adds a seventh asia-east2 cell at the C34 shape (cap 3000, 6000 request
units, pool 16, e2-standard-4) in asia-east2-a, pinned to image F. It gets
its own topology and registration wave but no promotion wave, so the
admission script and workflow refuse to promote it; it stays a
migration-only spare and out of the fleet pool list. Mirrors stablyai#25336.

* test(relay): accept the c35 spare under the same-cap capacity allowlist
…27690)

* perf(wsl): run ripgrep on the Windows host for drive-path projects

A project stored on a Windows drive (C:\...) with the WSL runtime selected
ran quick open, file-path search, content search and Markdown listing
through wsl.exe and the Linux rg reading /mnt/c over drvfs. rg only reads
files, so it has no git index whose stat cache two writers could thrash;
the host binary reads NTFS directly.

Measured on a 21.6k-file clone on C: (Windows 11, Ubuntu-24.04):
  content search  WSL rg 3.5 s  -> host rg.exe 0.19 s
  file listing    WSL rg 0.14 s + ~65 ms wsl.exe spawn -> host 0.03 s

Git routing is intentionally unchanged: alternating Windows git and WSL git
on the same index forced a full ~250 s rehash on the next WSL git status.

WSL UNC roots and non-drive roots keep their existing routing.

* fix(search): keep host rg results whole when files only WSL can open exist

Windows rg cannot open a 'nul' file, Win32-trimmed names, or WSL-created
symlinks; treat those per-file errors as skipped rather than failing or
truncating the search, and keep symlink-following scans in WSL.
The relay runtime ladder (rungs A/B/C/legacy/D, its self-test, refusal
cache, per-host decision store and its telemetry) lost its only caller
when the relay was deleted. Two pieces were still live: picking the Node
runtime a host can run by glibc (managed orcad deploy, WSL guest
runtime) and the runtime-store pins orcad version GC keeps. Those move
to pinned-runtime-host-target.ts; pick/durationBucket move into
ssh-host-server-telemetry.ts, their only remaining user.

Co-authored-by: m4air <[email protected]>
…tablyai#27720)

* refactor(startup): one agent-hook runtime binding set for every host

* fix(startup): read the hooks-enabled gate from its shared module

---------

Co-authored-by: m4air <[email protected]>
…7735)

* perf(zod): compile ACP updates and use Zod 4.6 boolean validation

* test(zod): expand regression coverage and move benchmark to PR body
…and focus (stablyai#26685)

* fix(native-chat): put chat text on one type scale that follows Text size

Sizes were picked per component, so the same kind of row came out 12, 13 or
14px and the Text size setting reached only a few of them.

* fix(native-chat): scale chat spacing and icons with Text size

Icons and gaps stayed fixed while text grew, so at larger sizes they looked
undersized and sat off-centre.

* fix(native-chat): implement PR stablyai#26685 review fixes

- Scale row gap with text size so controls don't overlap
- Clamp 'Match terminal interface' to 12-20 for labels/controls
- Use existing --status-warning token for warning color
- Rewrite stale test for scaled typography tokens
- Use app colors for in-progress tasks in composer dock

* fix(native-chat): leave the task list's dock colour as it was

* fix(native-chat): message text follows the terminal size; controls and spacing stay in 12-20

* test(native-chat): labels and spacing follow the bounded chat size; main's new notice test uses the chat colour

---------

Co-authored-by: Brennan Benson <[email protected]>
…27684)

* fix(wsl): stop booting stopped distros from background work

Any `wsl.exe -d` (or \\wsl.localhost access) boots a stopped distro: 1-2s of
VM boot, and on WSL < 3.0.1 its later idle-stop wipes the VM-wide WSLInterop
binfmt entry for every other running distro (microsoft/WSL#13885).

Add one gate (wsl-background-distro-gate.ts): background work checks
`wsl --list --running` (never boots), and stopped-distro work can be deferred
until the distro is next seen running (a confirmed running probe or a local
WSL terminal spawn).

- Startup CLI registration reconciliation: only running candidates; stopped
  ones are deferred per distro and stay registry candidates for later starts.
- Fish history GC: keeps the tombstone (and its meta.json) while the distro is
  stopped and finishes the cleanup once it runs; no admission slot is held.
- Codex/Claude/Kimi quota polls for WSL targets: skip while stopped (Codex
  keeps its last value). User-driven resets still boot.
- Codex WSL auth drain before an update restart: skip stopped distros (no
  live legacy pane there; the next launch prep drains anyway).

* fix(rate-limits): capture the Codex fetch generation before home resolution

The Codex home resolver is now async (it checks whether the WSL distro is
running), so a reset that lands during that await bumped the generation the
full-refresh cycle then read as its own, letting a stale result overwrite it.

Co-authored-by: Syed Zohaib Hussain <[email protected]>

* fix(wsl): read an unconfirmed running-distro probe as stopped in the background gate

* test(wsl): pin the empty running list wsl.exe reports when no distro runs

---------

Co-authored-by: Syed Zohaib Hussain <[email protected]>
* fix(native-chat): quote icon on Add to chat, and show it sooner after a double-click

* Restore double-click selection delay
* feat(serve): supervised mode for orca serve --supervise

Restart the server with jittered backoff instead of exiting when it dies,
with a crash-loop brake whose exhaustion is durable per profile and build,
an install hold while the executable is missing or ShipIt replaces the
bundle, and standby while another Orca serves the profile. Only an
explicit --supervise turns it on; Windows refuses it for now.

* fix(serve): let a supervised orcad serve wait for a live peer instead of counting it

* fix(serve): gate update replacements on the install hold, honor stop during the bundle wait, keep a give-up while the executable is missing

* fix(serve): hand a removed executable back to the service manager and key the brake on the app archive

---------

Co-authored-by: m4air <[email protected]>
Mirrors stablyai#25757 (c34): adds the c35 promotion wave, workflow promote and
canary case entries, the c35 canary evidence entry, tests, and docs.
stablyai#27621)

* fix(bench): resolve dynamically imported sources as file URLs

`await import(path.join(ROOT, '...ts'))` hands Node a bare Windows path
(`C:\...`), which the ESM loader rejects as an unsupported URL scheme
("Received protocol 'c:'"). The two benchmarks that load production
modules this way crashed on Windows before running a single scenario,
while working on macOS and Linux where an absolute path is a valid
specifier.

Wrap each computed specifier in `pathToFileURL(...).href`, the form the
other benchmark scripts already use for the same purpose.

Verified on Windows: bench:session-write-hot-path and
bench:agent-inspection-cadence now run and print their measurement
tables. The fish mode-2031 trace capture resolves its import too, but its
harness targets macOS/Linux shells and cannot complete on Windows.

Fixes stablyai#25235

* style(bench): format the session-write benchmark's file-URL import

---------

Co-authored-by: Paolo <[email protected]>
Co-authored-by: Orca Worker <orca-worker@localhost>
…ss table on Windows (stablyai#27622)

* fix(bench): make the idle-CPU benchmark run and report CPU on Windows

Three independent Windows defects in the idle-CPU benchmark (its report is
what Windows performance work would cite):

- `buildAppIfNeeded` spawned `npx`, which is `npx.cmd` on Windows, so
  execFileSync failed with ENOENT before any sampling. Build through
  `config/scripts/run-electron-vite-build.mjs` instead — the repo's own
  Windows-safe wrapper, which also runs the boot-graph verification.
- `readWindowsProcesses` returned `cpuTimeSeconds: null`, so the sampler's
  per-process CPU delta (idle-cpu-process-sampling.mjs:198) fell back to
  the hardcoded `percentCpu: 0` and every CPU KPI in the report was zero.
  Read `UserModeTime`/`KernelModeTime` from `Win32_Process` (100 ns units)
  and keep `null` when a host does not return them.

Measured on Windows, same options before and after the CPU fix:

| class | mean CPU before | mean CPU after |
| --- | ---: | ---: |
| renderer | 0 | 2.20 |
| gpu | 0 | 2.08 |
| utility | 0 | 0.11 |
| agent-or-node | 0 | 0.06 |
| total | 0 | 4.51 (p95 8.40) |

RSS is unchanged (934 MiB -> 937 MiB), so only the CPU reporting changed.

Refs stablyai#25235

* fix(bench): reject a missing Win32_Process time instead of reading it as zero

Review follow-up (CodeRabbit). `Number(null)` is `0`, which is also a real
counter value, so an absent `UserModeTime`/`KernelModeTime` passed the
finite check and the sampler would report a kernel-only delta instead of
taking the fallback. Require an actual number from the CIM payload.

Verified on Windows that the real payload still reports CPU once the check
is tight: total mean 4.40%, p95 14.48%, renderer 3.51%.

* test(bench): cover the Windows CIM CPU time mapping

The mapping was only reachable through Get-CimInstance, so no test ran it.
Lift it into cimCpuSeconds and assert the 100ns-to-seconds sum plus the
missing / string / non-finite cases that must stay null.

* fix(bench): read the Windows process table as UTF-8 so JSON.parse survives

PowerShell writes to a redirected stdout in the OEM code page (437 here),
which best-fits characters such as U+2022 and U+2192 in any running
process's command line to raw 0x07 / 0x1A bytes. ConvertTo-Json had left
them unescaped because they are not control characters in UTF-16, so the
sampler's JSON.parse failed with "Bad control character in string literal"
whenever such a process happened to be alive -- hence intermittent.

Set [Console]::OutputEncoding to UTF-8, as the app's own CIM scan does,
and cover it with a Windows-only test that fails without the fix.

Fixes stablyai#25236

* fix(bench): pass the local runtime to fetchRepos in the idle-CPU fixture

fetchRepos now requires a runtimeEnvironmentId, so the fixture's bare call
threw "Cannot read properties of undefined (reading 'runtimeEnvironmentId')"
before sampling on every platform. null selects this app's own catalog, as
the e2e helpers already do.

* ci(bench): run the Windows process-table test in the Windows lane

The UTF-8 regression test self-skips off win32, so it must be registered in
both Windows lists or it runs on no machine.

---------

Co-authored-by: Paolo <[email protected]>
Co-authored-by: Orca Worker <orca-worker@localhost>
* fix(chat): jump to messages without scrolling animation

* Jump to chat messages instantly instead of animating the scroll

Smooth scrolling let rows measured mid-animation shift the target, so jumps could land short or cancel near the end of the transcript. Jumps now write the scroll offset directly, and the align hook keeps its target until the row settles. Tests assert no smooth scroll is requested and that a loaded target lands within one frame.
…tablyai#27727)

* Skip unnecessary compatibility-boundary parsing and benchmark it in CI

* Use pinned preflight Bun for compatibility checks and localization extraction

* Measure two concurrent Bun projects in full preflight and update its scope test
…yai#27689)

The orcad/remote-install transport now exposes exec as a neutral
RemoteCommandChannel (a Duplex with stdin, stderr, close and exit/close
events) instead of ssh2's ClientChannel, and drops sftp(): the only
consumer was a fallback for doubles without writeFile/uploadDirectory,
which the transport type already requires. SshConnection still satisfies
the type structurally, so the SSH adapter keeps returning the connection
itself and identity-keyed caches are unchanged.

The stdio bridge provider is split: the loopback listener (admission,
queueing, socket piping) now takes a channel factory and knows nothing of
SSH; the SSH provider resolves and checks the bridge over the host
transport and hands the listener a factory. No behavior or wire change.
…7743)

* Share immutable historical source across local cross-version test caches

* Add preview-first cleanup of old historical test caches

* Include historical test cache cleanup in worktree space maintenance

* Report and retain read-only Electron installs during cleanup

* Protect read-only installs under root and isolate cleanup CLI fixtures
…p install (stablyai#27722)

* feat(updater): auto-park registered serve supervisors during a desktop install

* test(serve): drop a type assertion in the bundle park test

* fix(updater): stop any server started during an install hold and re-list blockers right before commit

---------

Co-authored-by: m4air <[email protected]>
…yai#27691)

* test(launch): pin what the "+" launchers and the AI buttons' window route produce on main

Row 1 ("+": menu, shortcut, dashboard) joins the window-tab table on both halves;
saved-arg tokenize failures before routing, the restart of a never-mounted "+" tab
and the AI-button host gate are pinned at the window planner.

* test(launch): cut "+" pins main already holds and check outcomes, not internals

Drop the AI-button and restart tests and the duplicate \\wsl$ folder and macOS
unclosed-quote rows; the Q5 pair now checks that no tab or startup was made.
…l (STA-10166) (stablyai#27748)

* fix(ssh): end an older Orca's relay terminals from the refusal, and name the command

* test: type confirmation mocks

* fix(ssh): match old relay daemons by argv position; owner-check the Windows command

* fix(ssh): select Windows relay daemons by argv position in the manual command

* fix(ssh): keep the relay daemon marker local so census mocks stay intact

---------

Co-authored-by: m4air <[email protected]>
)

* feat(serve): orca serve service install|status|uninstall for launchd and systemd user units

* fix(serve): redact pairing secrets in the supervisor instead of an inherited env, validate the port and launcher at install

* fix(serve): keep the redaction module off a direct child_process import

* fix(serve): redact the JSON readiness offer and survive a closed log pipe

---------

Co-authored-by: m4air <[email protected]>
Preserve fork entry points, Linux folder browsing, dictation replacement,
CI sharding and packaged helper safeguards. Record exact pins and tests.
Keep the shared browser compatible with the existing composer SSH caller
while retaining Linux local browsing and execution-host listing routes.
Preserve the fork installer and freshness classifier while adapting upstream
canonical-copy fixtures. Verify upstream-owned copies retain foreign-source
presence and nudge behavior.
Use deterministic timers for the WebView bridge fixture and clear pending
retries before restoring its globals. Verify bounded bridge retries and one
successful delivery when the bridge becomes available later.
@karlorz
karlorz merged commit e061a6f into fork-main Oct 12, 2026
84 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants