orca/docs
Neil a721125d06
fix(perf): correct three 07-27 perf regressions (#11234)
* fix(perf): correct three 07-27 perf regressions

Traversal capacity cap no longer scales with worker concurrency
(#11026). retainWorkspaceSpaceScanEntry charged a traversal-wide entry
counter, so N workers each holding a listing multiplied the live charge.
At concurrency 48 a 48x2,100 tree (100,848 entries) hit the 100,000 cap
while 100x1,500 (150,100 entries, 50% more) passed, and scanLocalWorktree
treats the capacity error as terminal, reporting an intact worktree as
"Unavailable" with sizeBytes 0. The cap is now per directory listing --
the only quantity fixed by directory shape -- restoring the invariant
docs/workspace-space-scan-resource-bounds.md already states. Aggregate
live retention stays bounded by the unchanged 64 MiB byte cap.

Note: releasing each entry's charge at dispatch (the originally suggested
fix) was measured and does not help; the peak is set at admission, before
any entry is dispatched.

Repo image icons are no longer fully base64-decoded on every snapshot
publish (#11012). sanitizeRepoIcon reached decodeBase64Prefix, which
sized its buffer to the whole payload to read a 24-byte header, running
synchronously inside ipcMain.handle at a 250 ms throttle. Validation is
now memoized on source+src in a BoundedMap. Measured for 10 icons x
256 KB: 37.34 ms -> 0.67 ms per publish.

One over-long card label no longer discards the entire snapshot (#11012).
isDashboardSnapshot was all-or-nothing and dashboard-popout returned
early with no log while replaying lastSnapshot, so `orca terminal rename
--title "<1025+ chars>"` froze the pop-out board on its last good paint
with nothing surfaced. Labels are truncated at the producer, the
validator drops only the offending card, and both the rejection and the
drop are logged. The bound now lives in the shared snapshot contract so
producer and validator cannot drift.

Co-authored-by: Orca <help@stably.ai>

* fix(perf): charge a scan listing's parent path once, not per entry

The 4.1 fix made the entry cap per-listing but left the 64 MiB byte cap
charging parentPath.length for every entry in a listing. Because a
listing's entries all share one parent-path string, that multiplied the
path by the directory's width, so the byte cap measured checkout depth
rather than live heap.

The reported symptom therefore still reproduced at the production default
limits: 48 x 2,100 @ concurrency 48 raised a capacity error once the
worktree path passed ~58 characters, while the same layout at concurrency
1 succeeded. The shipped regression test could not see this because it
passes maxRetainedBytes: Number.MAX_SAFE_INTEGER, disabling the only cap
still in play. Measured at a real 65-char worktree root, 3 of the report's
4 documented layouts still failed.

The parent path is now charged once per listing, with its first entry, so
an empty listing strands no charge. Per-entry overhead is unchanged at
512 B + name, which still dominates the estimate, so the OOM protection
the original PR added is preserved.

Adds a production-default-limits case covering the report's layouts under
a deep root, plus an assertion that a short and a deep root reach the same
verdict -- the path independence docs/workspace-space-scan-resource-bounds.md
requires and which no existing test enforced.

Co-authored-by: Orca <help@stably.ai>

* fix(perf): prove the icon cache by decode count, not wall clock

The caching test asserted a per-publish millisecond budget, which failed
on CI at 5.64 ms against a 5 ms ceiling. Any threshold flakes on a loaded
box, so count real sanitizeRepoIcon entries instead: 10 repos x 20
publishes is 200 icon checks against exactly 1 decode. Added cases pin
the cache key (payload and source both re-decode; a cached image verdict
never answers for an emoji) and that a rejection is cached too.

Also drops budget.entries, which the per-listing cap left as a
traversal-wide counter no check reads -- exactly the shape a future
guard could reintroduce the concurrency bug from.

Co-authored-by: Orca <help@stably.ai>

* fix(dashboard): bound the project filter label the whole board rides on

#11042 added snapshot-level filterOptions whose project labels are
repo.displayName -- the same unbounded source this PR already bounds for
card.repoName, but one level up where dropping a card cannot recover it.
An over-long project name would fail isDashboardFilterOptions and take
the entire snapshot with it, which is the exact frozen-board failure the
per-card drop was added to end. Workspace-status labels are already
capped at 32 by workspace-statuses.ts, so only projects needed this.

Co-authored-by: Orca <help@stably.ai>

* fix(dashboard): disambiguate the repo icon cache key

The memoization key joined `source` and `src` with a space, but the
sanitizer's base64 pattern admits whitespace inside a valid `src`. A
rejected icon can therefore split the same concatenation differently and
inherit an accepted icon's cached verdict, reaching the pop-out's
`<img src>` without ever being sanitized. Length-prefix the source.

Co-authored-by: Orca <help@stably.ai>

---------

Co-authored-by: Orca <help@stably.ai>
2026-07-28 17:08:14 -07:00
..
assets docs: add WeChat group 6 QR with overflow guidance 2026-07-28 01:36:06 -07:00
bug-reproductions/8979-screenshots fix(rate-limits): surface Fable weekly usage when is_active is false (#8979) (#9389) 2026-07-20 00:39:08 -07:00
readme docs: add WeChat group 6 QR with overflow guidance 2026-07-28 01:36:06 -07:00
reference feat: bound direct SSH reconnect fan-out and recovery (#11003) 2026-07-28 12:33:17 -07:00
STYLEGUIDE.md
agent-status-over-wsl.md
android-emulation-streaming.md
android-emulation.md
automations-navigation-stack.md
browser-normal-download-behavior.md
claude-fable-weekly-usage-meter.md
claude-scoped-oauth-usage-limits.md fix(rate-limits): surface Fable weekly usage when is_active is false (#8979) (#9389) 2026-07-20 00:39:08 -07:00
claude-usage-tracking-codexbar-parity.md
cmd-j-tab-session-search.md
compact-worktree-card-setting-graduation.md
configurable-open-in-menu.md
delete-workspace-windows-unregistered.md
double-tap-modifier-keybindings-design.md
droid-orchestration-group.md
editor-find-layout-aware-shortcut.md Fix layout-aware find in the source editor (#8088) 2026-07-10 03:56:55 -07:00
failed-automation-rerun-action.md
floating-terminal-panel-position-persistence.md
github-tasks-close-reason-parity.md
image-viewer-pinch-zoom.md
issue-7649-vscode-wsl-launch.md
kill-all-sessions-also-kills-empty-terminals.md chore: remove release-scan artifact and trailing whitespace (#8184) 2026-07-10 17:13:39 -07:00
linear-issues-load-more.md
linear-scope-selector.md
native-chat-codex-tui-parity.md
new-worktree-sidebar-reveal.md
orchestration-primitives.html Implement robust orchestration primitives and connected-server workers (#9925) 2026-07-27 12:31:37 -07:00
orchestration-reset-scope-validation.md
persist-tree-view-source-control.md
refresh-github-issues-after-create.md
remote-web-paste-activity-fixes.md
renderer-memory-profile-2026-06-01.md
show-full-tab-title-tooltip.md
source-control-push-failure-ai-recovery.md
ssh-config-target-compatibility.md
ssh-handler-reregistration-port-forwards.md
terminal-close-confirmation.md
terminal-main-owned-state.md Terminal performance initiative: pipeline fixes + term-speed-2 revival + PTY flow control (integration branch) (#7214) 2026-07-10 17:27:47 -07:00
terminal-scroll-intent-architecture.md
windows-secure-file-acl-hardening.md
workspace-space-scan-resource-bounds.md fix(perf): correct three 07-27 perf regressions (#11234) 2026-07-28 17:08:14 -07:00
worktree-delete-preflight.md
worktree-sidebar-drag-autoscroll.md
wrapped-terminal-file-link-fragments.md Fix hard-wrapped terminal file links (#8100) 2026-07-10 08:26:06 -07:00
wsl-osc7-sleep-wake-cwd.md fix: preserve WSL CWD across daemon sleep wake 2026-07-19 16:04:05 -07:00