Merge origin/main before final scanner validation
Preserve main source-root extraction and ordered scope-cache refreshes. Co-authored-by: Jinjing <6427696+AmethystLiang@users.noreply.github.com>
@@ -2,193 +2,42 @@
|
||||
|
||||
Thanks for contributing to Orca.
|
||||
|
||||
## Before You Start
|
||||
|
||||
- Found a security vulnerability? Do not open a public issue or PR; report it privately as described in [`SECURITY.md`](./SECURITY.md).
|
||||
- Keep changes scoped to a clear user-facing improvement, bug fix, or refactor.
|
||||
- Orca targets macOS, Linux, and Windows. Every change must stay compatible with all three platforms unless the code is explicitly guarded by a runtime platform check.
|
||||
- For keyboard shortcuts, use runtime platform checks in renderer code and `CmdOrCtrl` in Electron menu accelerators.
|
||||
- For shortcut labels, show `⌘` and `⇧` on macOS, and `Ctrl+` and `Shift+` on Linux and Windows.
|
||||
- For file paths, use Node or Electron path utilities such as `path.join`.
|
||||
- Orca must work against local repositories, remote servers, and SSH worktrees. Do not assume a process, file, credential, shell, or network path exists only on the local machine.
|
||||
- Orca supports many CLI agents, integrations, and git providers. Keep generic behavior provider-neutral; guard integration-specific logic behind explicit checks.
|
||||
- Keep changes well-engineered and performant: follow existing architecture, avoid unnecessary work in hot paths, clean up owned resources, and use concrete module names.
|
||||
- For UI work, follow [`docs/STYLEGUIDE.md`](../docs/STYLEGUIDE.md), use the tokens and shadcn primitives it specifies, and verify polished behavior across platforms, light/dark mode, and SSH latency.
|
||||
Found a security vulnerability? Do not open a public issue or PR; report it privately as described in [`SECURITY.md`](./SECURITY.md).
|
||||
|
||||
## Local Setup
|
||||
|
||||
Install Node 24, pnpm, and the Bun version in [`config/.bun-version`](../config/.bun-version).
|
||||
`pnpm test` runs Vitest on Bun, with Node workers for runtime contracts such as SQLite,
|
||||
native PTYs, socket liveness, and V8 memory behavior. `pnpm test:node` runs the same suites
|
||||
entirely on Node. Builds and dependency installation still use Node and pnpm.
|
||||
|
||||
The server, its workers and its packaged dependencies target Node 24. The compatibility
|
||||
launcher and CLI still target Node 18; the launcher hands off to bundled Node 24 before
|
||||
loading server code. WSL guest programs and host discovery retain their Node 18 minimum.
|
||||
Keep Node 24 APIs and server imports out of these host compatibility paths. Running an
|
||||
unpackaged server directly requires Node 24 or newer.
|
||||
|
||||
Use the pnpm version in `packageManager` in [`package.json`](../package.json): `corepack enable`
|
||||
needs Corepack 0.34.5 or newer to start the pinned pnpm (`npm install -g corepack@latest`). On
|
||||
Windows it writes shims next to `node.exe` and fails with `EPERM` outside an elevated shell when
|
||||
Node is in `C:\Program Files\nodejs`; run `npm install -g pnpm@<that version>` instead.
|
||||
|
||||
`pnpm install` compiles native modules such as `node-pty` with `node-gyp` and loads them in
|
||||
Electron, so a fresh machine also needs:
|
||||
|
||||
- **macOS**: Xcode Command Line Tools (`xcode-select --install`).
|
||||
- **Windows**: Python 3 and Visual Studio Build Tools with the "Desktop development with C++"
|
||||
workload.
|
||||
- **Linux**: a C++ toolchain, Python 3, and the libraries Electron loads even on a headless
|
||||
machine, plus `xvfb`, which the `*.electron.test.ts` files in `pnpm test` use when `DISPLAY` is
|
||||
unset. On Ubuntu 24.04+ and Debian 13+:
|
||||
|
||||
```bash
|
||||
sudo apt-get update && sudo apt-get install -y build-essential python3 xvfb libgtk-3-0 libnss3 libgbm1 libasound2t64
|
||||
```
|
||||
|
||||
Older releases name the last package `libasound2`.
|
||||
Install Node 24, the pnpm version in `packageManager` in [`package.json`](../package.json), and the Bun version in [`config/.bun-version`](../config/.bun-version). `pnpm install` compiles native modules, so you also need a C++ toolchain and Python 3 (Xcode Command Line Tools on macOS, Visual Studio Build Tools on Windows, `build-essential` and Electron's libraries on Linux).
|
||||
|
||||
```bash
|
||||
pnpm install
|
||||
pnpm -C mobile install --frozen-lockfile # mobile/ has its own lockfile; build and lint need it
|
||||
pnpm dev
|
||||
```
|
||||
|
||||
`mobile/` is a separate pnpm project with its own lockfile, so the root `pnpm install` leaves its
|
||||
dependencies uninstalled. `pnpm build` (`build:mobile-web` fails without them) and the lint
|
||||
passes that cover `mobile/` need them. Install them before building or linting, and again
|
||||
when `mobile/pnpm-lock.yaml` changes:
|
||||
`pnpm dev` in a linked Git worktree uses its own profile and ports, so instances in different worktrees run side by side.
|
||||
|
||||
```bash
|
||||
pnpm -C mobile install --frozen-lockfile
|
||||
```
|
||||
|
||||
### Dev Profiles and Parallel Instances
|
||||
|
||||
`pnpm dev` in a linked Git worktree uses its own userData profile, renderer port, and remote
|
||||
debugging (CDP) port, so dev instances in different worktrees run side by side. The main checkout
|
||||
keeps the shared `orca-dev` profile. Ports are derived from the worktree path and move to the next
|
||||
free port when taken: renderer ports start at 15200 and CDP ports at 9333.
|
||||
|
||||
On startup the runner prints one stdout line and writes the same JSON to `out/dev-instance.json`:
|
||||
|
||||
```text
|
||||
ORCA_DEV_INSTANCE {"userData":".../orca-dev-wt/1d3830d4d3","profile":"worktree","rendererPort":15339,"rendererUrl":"http://localhost:15339","cdpPort":9513,"cdpUrl":"http://127.0.0.1:9513","repoRoot":"...","runnerPid":4242}
|
||||
```
|
||||
|
||||
| Option | Effect |
|
||||
| ----------------------------------------------------------------------- | ---------------------------------------------------------- |
|
||||
| `pnpm dev --shared-profile` or `ORCA_DEV_PROFILE=shared` | Use the shared `orca-dev` profile |
|
||||
| `pnpm dev --worktree-profile` or `ORCA_DEV_PROFILE=worktree` | Use a per-worktree profile, including in the main checkout |
|
||||
| `ORCA_DEV_USER_DATA_PATH=<dir>` | Use an explicit profile directory |
|
||||
| `REMOTE_DEBUGGING_PORT=<port>`, `ORCA_DEV_RENDERER_PORT=<port>` | Pin a port |
|
||||
| `pnpm dev --seed-profile[=<dir>]` or `ORCA_DEV_SEED_PROFILE=<dir or 1>` | Seed an empty profile on first launch |
|
||||
|
||||
Per-worktree profiles live in `orca-dev-wt/<hash>` next to `orca-dev` (`~/Library/Application
|
||||
Support` on macOS, `%APPDATA%` on Windows, `$XDG_CONFIG_HOME` or `~/.config` on Linux). The
|
||||
automatic storage cleanup removes them once their worktree is gone and nothing still runs from
|
||||
them. `config/scripts/orca-dev.mjs` and the `orca-dev` terminal wrapper target the profile this
|
||||
checkout's `pnpm dev` used.
|
||||
|
||||
Seeding copies a slim set of state from another profile: projects, workspaces, settings, SSH
|
||||
targets, and the Orca account session. Terminal sessions, PTY leases, automations, caches, logs,
|
||||
and lock files are not copied, and the source profile is only read. The default source is
|
||||
`orca-dev`, or the installed app's profile when `orca-dev` is empty. Seed from `orca-dev` when you
|
||||
need the signed-in account session: dev builds cannot decrypt secrets the installed app encrypted.
|
||||
|
||||
```bash
|
||||
pnpm dev:seed-profile [--from=<profile dir>] [--to=<profile dir>] [--reset]
|
||||
pnpm dev:fresh [--keep] [--seed-from[=<profile dir>]] # temporary profile, removed on exit
|
||||
```
|
||||
|
||||
### Targeting Local Tests
|
||||
|
||||
Use a test file or directory when you know the relevant suites. For dependency-based
|
||||
feedback, Vitest can select tests affected by your edits:
|
||||
|
||||
```bash
|
||||
pnpm test:changed src/main/runtime --maxWorkers=2
|
||||
pnpm test --changed=origin/main --maxWorkers=2
|
||||
pnpm test src/shared/automations/scheduling/automation-cron-input-validation.test.ts --maxWorkers=2
|
||||
```
|
||||
|
||||
`test:changed` considers staged, unstaged, and untracked files. `--changed=origin/main`
|
||||
also includes committed changes since the branch's merge base. Update that ref when
|
||||
you need a newer baseline. Both accept the same path filters and options as `pnpm test`.
|
||||
When Git reports no changed files at all, the launcher exits before starting Vitest.
|
||||
|
||||
Affected tests use Vitest's static import graph. Run suites explicitly for computed
|
||||
dynamic imports, fixture files, subprocess inputs, or other dependencies outside that
|
||||
graph. Local affected tests do not replace CI.
|
||||
|
||||
Use `pnpm test`, not raw `vitest`: only it keeps the transform cache that makes repeat runs fast.
|
||||
|
||||
Most unit files share a worker and its module cache with the files before them. After each file
|
||||
the worker undoes mocks, fake timers, stubs, env, cwd, and leftover timers, listeners, and globals.
|
||||
Files using `vi.doMock`, `vi.resetModules`, a DOM environment, or direct `globalThis` writes keep
|
||||
their own worker. If a file passes alone but fails after others, add `// @orca-isolated-worker`
|
||||
to it; `ORCA_VITEST_ISOLATE_EVERY_FILE=1` isolates every file to confirm a leak.
|
||||
|
||||
To reduce main-process rebuild CPU and memory when you do not need its source maps,
|
||||
set `ORCA_DEV_MAIN_SOURCEMAPS=0` before `pnpm dev`. In Bash/zsh:
|
||||
|
||||
```bash
|
||||
ORCA_DEV_MAIN_SOURCEMAPS=0 pnpm dev
|
||||
```
|
||||
|
||||
In PowerShell, use `$env:ORCA_DEV_MAIN_SOURCEMAPS='0'` before `pnpm dev`.
|
||||
Remove the variable when debugging the main process with source maps. Renderer and
|
||||
preload settings are unaffected; production builds always keep their hidden main maps.
|
||||
|
||||
`pnpm dev` serves the renderer with Vite's bundled dev mode: a few bundled chunks instead of
|
||||
thousands of module requests, so the first render and full reloads are faster. While a rebuild is
|
||||
pending, a newly opened pop-out, space, or web window may briefly get placeholder HTML. If the
|
||||
renderer misbehaves, set `ORCA_DEV_BUNDLED=0` (PowerShell: `$env:ORCA_DEV_BUNDLED='0'`) and report it.
|
||||
|
||||
Local installs use pnpm's global virtual store: each package version is one slot
|
||||
under `~/pnpm/store` that every worktree links to, instead of a full `node_modules` per worktree.
|
||||
An existing worktree converts on its next `pnpm install`, and an older branch without the setting
|
||||
converts back the same way. CI always uses the normal layout. On Windows, pnpm links with
|
||||
junctions when you lack the symlink privilege, so no administrator rights or Developer Mode are
|
||||
needed. Things to know:
|
||||
|
||||
- Keep `~/node_modules` (and any other `node_modules` above the store) out of your home
|
||||
directory. Node resolves upward from the store slot, so a stray one there supplies
|
||||
dependencies the package never declared and hides missing-dependency bugs; `pnpm install` warns
|
||||
when it finds one.
|
||||
- Native addons are never rebuilt in place in a shared slot: each CPU gets its own build
|
||||
beside it (see [`native-build-entry.cjs`](../config/scripts/native-build/node-addons/native-build-entry.cjs)), so
|
||||
cross-arch packaging is safe for other worktrees.
|
||||
- `ORCA_PNPM_GLOBAL_VIRTUAL_STORE=0` opts out. Keep it set
|
||||
in your shell: `pnpm run` re-checks the install and relinks a worktree whose layout no longer
|
||||
matches.
|
||||
|
||||
Ordinary installs include native optional dependencies for the current OS and CPU only.
|
||||
Before a cross-architecture build (including `pnpm build:mac`, which produces both x64 and
|
||||
arm64 artifacts by default), run `pnpm install:release` to add the other CPU's variants.
|
||||
|
||||
Linux `pnpm build`, `pnpm build:native`, and Linux packaging require a running Docker
|
||||
daemon to build the clipboard helper against Ubuntu 20.04 rather than the host's
|
||||
newer libraries. A verified cached helper can be reused without Docker. For native
|
||||
Wayland development, run `pnpm build:native` before `pnpm dev` to make text copying
|
||||
available. See the [clipboard build guide](../native/wayland-clipboard/README.md#building-and-testing).
|
||||
macOS and Windows builds do not use this helper or require Docker for it.
|
||||
See [`docs/development.md`](../docs/development.md) for per-OS packages, Corepack and Windows notes, dev profiles and seeding, cross-architecture and Linux (Docker) builds, and troubleshooting.
|
||||
|
||||
## Branch Naming
|
||||
|
||||
Use a clear, descriptive branch name that reflects the change.
|
||||
Use a clear, descriptive branch name that reflects the change, such as `fix/ctrl-backspace-delete-word`, `feat/shift-enter-newline`, or `chore/update-contributor-guide`. Avoid vague names like `test`, `misc`, or `changes`.
|
||||
|
||||
Good examples:
|
||||
## Code Guidelines
|
||||
|
||||
- `fix/ctrl-backspace-delete-word`
|
||||
- `feat/shift-enter-newline`
|
||||
- `chore/update-contributor-guide`
|
||||
- Keep changes scoped to a clear user-facing improvement, bug fix, or refactor.
|
||||
- Orca targets macOS, Linux, and Windows. Guard platform-specific code with runtime checks, use `CmdOrCtrl` in Electron menu accelerators, show `⌘`/`⇧` labels on macOS and `Ctrl+`/`Shift+` elsewhere, and build paths with `path.join`. See [cross-platform support](../docs/agents-md-refs/cross-platform-support.md).
|
||||
- Orca must work against local repositories, remote servers, and SSH worktrees. Do not assume a process, file, credential, shell, or network path exists only on the local machine.
|
||||
- Keep generic behavior provider-neutral across CLI agents, integrations, and git providers; guard integration-specific logic behind explicit checks.
|
||||
- Follow existing architecture, avoid unnecessary work in hot paths, clean up owned resources, and use concrete module names.
|
||||
- For UI work, follow [`docs/STYLEGUIDE.md`](../docs/STYLEGUIDE.md) and verify behavior across platforms, light/dark mode, and SSH latency.
|
||||
|
||||
Avoid vague names like `test`, `misc`, or `changes`.
|
||||
### Type Declarations: Prefer `.ts` Over `.d.ts`
|
||||
|
||||
## Before Opening a PR
|
||||
Put project-owned types in `.ts` files. `.d.ts` is reserved for ambient shims (e.g., `env.d.ts`). `skipLibCheck: true` applies to our own `.d.ts` files too, so an unresolved type reference there silently becomes `any`. CI enforces this for `src/preload/` and `src/shared/`.
|
||||
|
||||
Run the same checks that CI runs, after the `mobile/` install from [Local Setup](#local-setup):
|
||||
## Checks Before Opening a PR
|
||||
|
||||
Run the same checks CI runs, after the `mobile/` install above:
|
||||
|
||||
```bash
|
||||
pnpm lint
|
||||
@@ -197,102 +46,28 @@ pnpm test
|
||||
pnpm build
|
||||
```
|
||||
|
||||
`pnpm lint` runs independent checks in a bounded pool. Use
|
||||
`pnpm lint --maxWorkers=2 --timings` to limit concurrent checks and print their durations.
|
||||
For faster repeat typechecks use `pnpm tc` (or `pnpm tc:node`, `pnpm tc:web`, `pnpm tc:cli`); run `pnpm tc:node` after editing shared tests.
|
||||
|
||||
For repeated local typechecks, use `pnpm tc` (or `pnpm tc:node`, `pnpm tc:web`,
|
||||
and `pnpm tc:cli`). On Apple Silicon macOS and x64/arm64 Linux, these use the pinned
|
||||
`tsrs` compiler with incremental caches. Keep `.cache/typecheck/` between checks;
|
||||
delete it to force a fresh check. Caches are separate for each project, compiler
|
||||
version, and worktree. At most two projects run together, subject to the memory budget.
|
||||
Windows, Intel macOS, and other unsupported platforms use pinned Bun automatically.
|
||||
Pass `--compiler=bun` to explicitly use Bun, or `--compiler=native` to use TypeScript.
|
||||
CI uses `pnpm typecheck:ci`, which explicitly selects Bun and its CI concurrency.
|
||||
Shared tests are checked by the
|
||||
Node project; shared production code is checked in all three environments.
|
||||
Run `pnpm tc:node` after editing shared tests, or `pnpm tc` to check everything.
|
||||
Add a test when it would catch a regression of your behavior change or bug fix, not for shallow coverage; see [test anti-patterns](../docs/agents-md-refs/test-antipatterns.md). If your change affects UI or interaction behavior, verify it on the platforms it could impact.
|
||||
|
||||
Add high-quality tests for behavior changes and bug fixes. Prefer tests that would actually catch a regression, not shallow coverage that only exercises the happy path.
|
||||
### Targeting Local Tests
|
||||
|
||||
If your change affects UI or interaction behavior, verify it on the platforms it could impact.
|
||||
Use `pnpm test`, not raw `vitest`: only it keeps the transform cache that makes repeat runs fast.
|
||||
|
||||
## Type Declarations: Prefer `.ts` Over `.d.ts`
|
||||
```bash
|
||||
pnpm test src/shared/automations/scheduling/automation-cron-input-validation.test.ts --maxWorkers=2
|
||||
pnpm test:changed src/main/runtime --maxWorkers=2 # staged, unstaged, and untracked changes
|
||||
pnpm test --changed=origin/main --maxWorkers=2 # also commits since the merge base
|
||||
```
|
||||
|
||||
Project-owned type declarations belong in `.ts` files. `.d.ts` is reserved for ambient shims (e.g., `env.d.ts`, `vite/client.d.ts`). TypeScript's `skipLibCheck: true` setting applies globally, including to our own `.d.ts` files, which means any unresolved type reference in a `.d.ts` silently becomes `any` at its call sites. Write your types in `.ts` files so the compiler actually checks them.
|
||||
|
||||
CI enforces this for `src/preload/` and `src/shared/`.
|
||||
Affected tests follow Vitest's static import graph, so run suites explicitly for dynamic imports, fixtures, or subprocess inputs. Local affected tests do not replace CI. If a file passes alone but fails after others, add `// @orca-isolated-worker` to it.
|
||||
|
||||
## Pull Requests
|
||||
|
||||
Each pull request should follow [`.github/pull_request_template.md`](./pull_request_template.md). In particular:
|
||||
Fill in every section of [`.github/pull_request_template.md`](./pull_request_template.md): an ELI5, what changed and why, a linked issue (required for outside contributors), a before and after (screenshots or videos) for any UI or behavior change (only if there is truly no visual or interaction change, write exactly `N/A` and briefly say why), how you tested it, the risk, and under Review a short summary from your AI coding agent covering cross-platform, SSH/remote, agent and integration compatibility, performance, UI quality, and security. Keep each PR small and focused on one topic.
|
||||
|
||||
- if you are an outside contributor, link the issue your PR addresses
|
||||
- open with an ELI5 of the change (plain language paragraph; the PR title is the one-liner)
|
||||
- explain what changed and why, and stay focused on a single topic when possible
|
||||
- for any UI or interaction change, attach **before and after** screenshots (or short videos); if there is no visual or interaction change, write `N/A` and briefly explain why
|
||||
- include high-quality tests when behavior changes or bug fixes warrant them
|
||||
- include a brief code review summary from your AI coding agent that explicitly checks cross-platform compatibility, SSH/remote/local compatibility, supported agent and integration compatibility, performance risk, UI quality when applicable, and basic security risk
|
||||
- mention any platform-specific, remote/SSH-specific, agent-specific, integration-specific, or git-provider-specific behavior and testing notes
|
||||
- **Include your X (Twitter) handle** in the PR template Author section — we shout out contributors when we merge features on [@orca_build](https://x.com/orca_build).
|
||||
Version bumps, tags, and releases are maintainer-managed. Do not include release version changes unless a maintainer asks. Maintainers cut releases with the [Cut Release](https://github.com/stablyai/orca/actions/workflows/release-cut.yml) workflow.
|
||||
|
||||
## Release Process
|
||||
## Getting Help
|
||||
|
||||
Version bumps, tags, and releases are maintainer-managed. Do not include release version changes in a normal contribution unless a maintainer asks for them.
|
||||
|
||||
### Cutting a release (maintainers)
|
||||
|
||||
All releases are cut from the **Cut Release** GitHub Actions workflow. There is no local `pnpm release:*` script — running releases locally is too easy to get wrong (dirty tree, wrong branch, stale main).
|
||||
|
||||
**To cut a release:**
|
||||
|
||||
1. Open [Actions → Cut Release](../../actions/workflows/release-cut.yml).
|
||||
2. Click **Run workflow** and pick:
|
||||
- **kind**: one of `rc`, `patch`, `minor`, `major`.
|
||||
- **ref**: the branch, tag, or SHA to build from. Defaults to `main`.
|
||||
3. Run it.
|
||||
|
||||
The workflow resolves the next version from GitHub Releases, bumps `package.json`, tags, pushes, and runs the multi-platform build + publish inline.
|
||||
|
||||
**How the next version is chosen:**
|
||||
|
||||
All stable kinds (`patch`, `minor`, `major`) are computed off the latest _stable_ release, ignoring any RCs in between.
|
||||
|
||||
- `kind=rc` + last tag was stable (e.g. `v1.3.14`) → `v1.3.15-rc.0`.
|
||||
- `kind=rc` + active RC series (e.g. `v1.3.15-rc.2`) → `v1.3.15-rc.3`.
|
||||
- `kind=patch` + latest stable `v1.3.14` → `v1.3.15` (regardless of any intermediate RCs).
|
||||
- `kind=minor` + latest stable `v1.3.14` → `v1.4.0`.
|
||||
- `kind=major` + latest stable `v1.3.14` → `v2.0.0`.
|
||||
|
||||
**Safety guarantees:**
|
||||
|
||||
- Stable releases are refused if the new version isn't strictly greater than the latest published stable. This is the only rule `electron-updater` actually needs — it compares semver within the `latest` channel, so a regressing stable is the one thing that breaks auto-update for fresh installs.
|
||||
- Complete RC draft releases created by the release workflow are published before cutting a new tag only when the draft tag was built from the current release ref. Stale drafts are skipped so fixes cut a fresh RC instead of exposing old artifacts.
|
||||
- If the latest RC tag exists but is still draft-only or missing its GitHub Release, the workflow resumes that tag only when it was built from the current release ref. Otherwise the next RC number is cut.
|
||||
- RC numbering also considers release commits on `main`, so deleting a stale tag does not let a later cut reuse the same RC number.
|
||||
- Off-main releases (when `ref` is not the tip of `main`) only push the tag. `main` is never mutated from a non-main ref, so you can safely release an older commit without polluting history.
|
||||
- When `ref` is the tip of `main`, the workflow tries to fast-forward the version-bump commit onto `main`. If main requires pull requests, it leaves main unchanged and pushes only the release tag. Other push errors still stop the cut.
|
||||
|
||||
**Common scenarios:**
|
||||
|
||||
- **Normal release:** `kind=patch`, `ref=main`.
|
||||
- **"A bad commit just landed on main, release the commit before it":** `kind=patch`, `ref=<good-sha>`. `main` is left alone; the tag points at the good SHA. Fix forward on `main` afterward.
|
||||
- **One-off RC for a feature branch:** `kind=rc`, `ref=<branch-or-sha>`. Produces an RC tag that does not touch `main`.
|
||||
- **Minor or major bump:** `kind=minor` or `kind=major`.
|
||||
|
||||
## Release Channels
|
||||
|
||||
The public Homebrew cask tracks stable desktop releases:
|
||||
|
||||
```bash
|
||||
brew install --cask stablyai/orca/orca
|
||||
```
|
||||
|
||||
Release candidates use a separate cask token:
|
||||
|
||||
```bash
|
||||
brew install --cask stablyai/orca/orca@rc
|
||||
```
|
||||
|
||||
The two casks conflict because both install `Orca.app`. Switch channels with a
|
||||
normal `brew uninstall --cask` followed by the install for the other channel.
|
||||
Do not use `--zap` unless you intentionally want to remove local Orca state.
|
||||
Ask questions on [Discord](https://discord.gg/fzjDKHxv8Q), or open an [issue](https://github.com/stablyai/orca/issues/new/choose) for bugs and feature requests.
|
||||
|
||||
@@ -19,7 +19,6 @@ on:
|
||||
# Contracts without the .performance suffix. Keep in sync with config/vitest.performance.config.ts;
|
||||
# without these a rename lands green and only breaks the next nightly.
|
||||
- 'src/main/runtime/session-tabs/session-tabs-phone-layout-moves.test.ts'
|
||||
- 'src/renderer/src/components/terminal-pane/pty-connection/startup/saved-resume-cancellation.test.ts'
|
||||
- 'src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-terminal-writer-acquire.test.ts'
|
||||
- 'src/shared/agent-launch/permissions/tui-agent-permission-choice.test.ts'
|
||||
- 'src/main/runtime/rpc/methods/projects/repo.test.ts'
|
||||
@@ -30,10 +29,8 @@ on:
|
||||
- 'src/main/codex-usage/scanner-incremental-append.test.ts'
|
||||
- 'src/main/usage/jsonl-file-reader.test.ts'
|
||||
- 'src/main/usage/jsonl-file-snapshot.test.ts'
|
||||
- 'src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler-queue-retention.test.ts'
|
||||
- 'src/main/claude-usage/scanner-incremental-append.test.ts'
|
||||
- 'src/main/claude-usage/store-checkpoint-persistence.test.ts'
|
||||
- 'src/renderer/src/components/native-chat/surfaces/integration/NativeChatResolvedView.streaming-input.test.tsx'
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
@@ -512,6 +512,10 @@ jobs:
|
||||
if: needs.code_paths.outputs.static_analysis == 'true'
|
||||
run: bun config/scripts/localization/source-extraction/audit-localization-coverage.mjs --check
|
||||
|
||||
- name: Verify startup and worktree localization coverage
|
||||
if: needs.code_paths.outputs.static_analysis == 'true'
|
||||
run: bun run verify:startup-worktree-localization-coverage
|
||||
|
||||
- name: Verify mobile localization
|
||||
if: needs.code_paths.outputs.static_analysis == 'true'
|
||||
run: bun config/scripts/localization/catalog-validation/verify-mobile-localization.mjs
|
||||
|
||||
@@ -99,6 +99,7 @@ docs/**
|
||||
!docs/bug-reproductions/
|
||||
!docs/bug-reproductions/**
|
||||
!docs/STYLEGUIDE.md
|
||||
!docs/development.md
|
||||
!docs/styleguide/
|
||||
!docs/styleguide/**
|
||||
!docs/agents-md-refs/
|
||||
@@ -120,6 +121,9 @@ validation-screenshots/
|
||||
test-results/
|
||||
playwright-report/
|
||||
|
||||
# Claude Code settings are machine-local.
|
||||
**/.claude/settings.local.json
|
||||
|
||||
# Agent skills are installed per machine.
|
||||
/.claude/skills/
|
||||
/.agents/skills/
|
||||
|
||||
@@ -272,6 +272,8 @@ _Or via a package manager:_
|
||||
brew install --cask stablyai/orca/orca
|
||||
# Upgrade an existing install
|
||||
brew upgrade --cask stablyai/orca/orca
|
||||
# Release candidates (conflicts with the stable cask; uninstall it first)
|
||||
brew install --cask stablyai/orca/orca@rc
|
||||
|
||||
# Arch Linux (AUR) — or stably-orca-git to build from source
|
||||
yay -S stably-orca-bin
|
||||
@@ -290,11 +292,9 @@ Pair with your desktop app to monitor and steer your agents from your phone.
|
||||
|
||||
- **Discord:** Join the community on **[Discord](https://discord.gg/fzjDKHxv8Q)**.
|
||||
- **Twitter / X:** Follow **[@orca_build](https://x.com/orca_build)** for updates and announcements.
|
||||
- **WeChat:** Scan to join an Orca community WeChat group. If one group is full, join another.
|
||||
- **WeChat:** Scan to join an Orca community WeChat group.
|
||||
|
||||
<img src="docs/assets/wechat-qr-group14.jpg" alt="WeChat QR code for the Orca community" width="160" />
|
||||
<img src="docs/assets/wechat-qr-group15.jpg" alt="WeChat QR code for the Orca community" width="160" />
|
||||
<img src="docs/assets/wechat-qr-group16.jpg" alt="WeChat QR code for the Orca community" width="160" />
|
||||
<img src="docs/assets/wechat-qr.jpg" alt="WeChat QR code for the Orca community" width="160" />
|
||||
|
||||
- **Feedback & Ideas:** We ship fast. Missing something? [Request a new feature](https://github.com/stablyai/orca/issues).
|
||||
- **Privacy:** See the [privacy & telemetry docs](https://www.onorca.dev/docs/telemetry) for what anonymous usage data Orca collects and how to opt out.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Later run-all.ts checks against the same host: rebind, orphan grace, silence,
|
||||
// forced resets and pre-upgrade refusals.
|
||||
// forced resets.
|
||||
import WebSocket from 'ws'
|
||||
import { GRACE_MS, ORIGIN, PING_MS, PORT, SILENCE_MS, makeControl, openPhone, record, sleep, waitFor, type Ctx, type Control } from './run-all-harness'
|
||||
|
||||
@@ -89,12 +89,4 @@ export async function runLifecycleChecks(ctx: Ctx, main: Control, mainAck: Ack):
|
||||
back.client.closeNow()
|
||||
}
|
||||
|
||||
// Bad JWT -> 401 before upgrade; malformed host id -> 429.
|
||||
{
|
||||
const bad = new WebSocket(`ws://127.0.0.1:${PORT}/v1/host/control`, { headers: { authorization: 'Bearer nope' } })
|
||||
const status = await new Promise<number>((res) => bad.on('unexpected-response', (_q, r) => res(r.statusCode ?? 0)))
|
||||
const badHost = new WebSocket(`ws://127.0.0.1:${PORT}/v1/connect/short`)
|
||||
const s2 = await new Promise<number>((res) => badHost.on('unexpected-response', (_q, r) => res(r.statusCode ?? 0)))
|
||||
record('R11/R5 ES256 JWKS rejects bad token (401); malformed host id 429', status === 401 && s2 === 429, `${status},${s2}`)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,11 +100,6 @@ async function runTests(ctx: Ctx): Promise<void> {
|
||||
const mainAck = await main.client.connect()
|
||||
const transport = main.bindTransport(mainAck.generation)
|
||||
|
||||
// Alarm-driven app ping, answered by the shipped client's pong handler.
|
||||
await sleep(PING_MS * 3 + 300)
|
||||
record('R2/R5 alarm-driven JSON ping parsed by shipped client, pong keeps control alive',
|
||||
main.events.pings >= 2 && main.client.isLive(), `pings=${main.events.pings} live=${main.client.isLive()}`)
|
||||
|
||||
// Phone connect -> conn-open (strict, shipped parser) -> host data -> relay-hello (shipped parser).
|
||||
const phone = openPhone(ctx)
|
||||
const helloOk = await waitFor(() => phone.hello !== null, 5000)
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
id: claude-chat-entrypoint-callers
|
||||
snapshots:
|
||||
"import { withOrcaClaudeChatEntrypoint as stamp } from './claude-chat-entrypoint'":
|
||||
labels:
|
||||
- source: withOrcaClaudeChatEntrypoint
|
||||
style: primary
|
||||
start: 9
|
||||
end: 37
|
||||
'withOrcaClaudeChatEntrypoint(env, platform)':
|
||||
labels:
|
||||
- source: withOrcaClaudeChatEntrypoint
|
||||
style: primary
|
||||
start: 0
|
||||
end: 28
|
||||
@@ -0,0 +1,20 @@
|
||||
id: claude-chat-entrypoint-owner
|
||||
snapshots:
|
||||
"const env = { CLAUDE_CODE_ENTRYPOINT: 'orca' }":
|
||||
labels:
|
||||
- source: CLAUDE_CODE_ENTRYPOINT
|
||||
style: primary
|
||||
start: 14
|
||||
end: 36
|
||||
const identity = 'sdk-cli':
|
||||
labels:
|
||||
- source: sdk-cli
|
||||
style: primary
|
||||
start: 18
|
||||
end: 25
|
||||
"env['claude_code_entrypoint'] = 'other'":
|
||||
labels:
|
||||
- source: claude_code_entrypoint
|
||||
style: primary
|
||||
start: 5
|
||||
end: 27
|
||||
@@ -0,0 +1,14 @@
|
||||
id: claude-entrypoint-key-owner
|
||||
snapshots:
|
||||
"env[CLAUDE_ENTRYPOINT_ENV] = 'orca'":
|
||||
labels:
|
||||
- source: CLAUDE_ENTRYPOINT_ENV
|
||||
style: primary
|
||||
start: 4
|
||||
end: 25
|
||||
"import { CLAUDE_ENTRYPOINT_ENV as key } from './claude-chat-entrypoint'":
|
||||
labels:
|
||||
- source: CLAUDE_ENTRYPOINT_ENV
|
||||
style: primary
|
||||
start: 9
|
||||
end: 30
|
||||
@@ -0,0 +1,6 @@
|
||||
id: claude-chat-entrypoint-callers
|
||||
valid:
|
||||
- 'stripInheritedClaudeSessionEnv(env)'
|
||||
invalid:
|
||||
- 'withOrcaClaudeChatEntrypoint(env, platform)'
|
||||
- "import { withOrcaClaudeChatEntrypoint as stamp } from './claude-chat-entrypoint'"
|
||||
@@ -0,0 +1,8 @@
|
||||
id: claude-chat-entrypoint-owner
|
||||
valid:
|
||||
- 'const env = withOrcaClaudeChatEntrypoint(configured, platform)'
|
||||
- "const binary = 'orca'"
|
||||
invalid:
|
||||
- "const env = { CLAUDE_CODE_ENTRYPOINT: 'orca' }"
|
||||
- "env['claude_code_entrypoint'] = 'other'"
|
||||
- "const identity = 'sdk-cli'"
|
||||
@@ -0,0 +1,6 @@
|
||||
id: claude-entrypoint-key-owner
|
||||
valid:
|
||||
- "const binary = 'orca'"
|
||||
invalid:
|
||||
- "env[CLAUDE_ENTRYPOINT_ENV] = 'orca'"
|
||||
- "import { CLAUDE_ENTRYPOINT_ENV as key } from './claude-chat-entrypoint'"
|
||||
@@ -0,0 +1,117 @@
|
||||
id: claude-chat-entrypoint-owner
|
||||
language: typescript
|
||||
severity: error
|
||||
message: Keep the Claude identity literal in claude-chat-entrypoint.ts.
|
||||
files: ['src/**']
|
||||
ignores:
|
||||
- '**/*.test.*'
|
||||
- '**/*.test-fixtures.*'
|
||||
- '**/__fixtures__/**'
|
||||
- 'src/shared/agent-launch/startup/claude-chat-entrypoint.ts'
|
||||
rule:
|
||||
all:
|
||||
- any:
|
||||
- kind: string_fragment
|
||||
- kind: property_identifier
|
||||
- kind: identifier
|
||||
- regex: '(?i)^(CLAUDE_CODE_ENTRYPOINT|sdk-cli)$'
|
||||
---
|
||||
id: claude-chat-entrypoint-owner-tsx
|
||||
language: tsx
|
||||
severity: error
|
||||
message: Keep the Claude identity literal in claude-chat-entrypoint.ts.
|
||||
files: ['src/**']
|
||||
ignores:
|
||||
- '**/*.test.*'
|
||||
- '**/*.test-fixtures.*'
|
||||
- '**/__fixtures__/**'
|
||||
- 'src/shared/agent-launch/startup/claude-chat-entrypoint.ts'
|
||||
rule:
|
||||
all:
|
||||
- any:
|
||||
- kind: string_fragment
|
||||
- kind: property_identifier
|
||||
- kind: identifier
|
||||
- regex: '(?i)^(CLAUDE_CODE_ENTRYPOINT|sdk-cli)$'
|
||||
---
|
||||
id: claude-chat-entrypoint-callers
|
||||
language: typescript
|
||||
severity: error
|
||||
message: Only structured native chat and its own probes may apply the chat identity.
|
||||
files: ['src/**']
|
||||
ignores:
|
||||
- '**/*.test.*'
|
||||
- '**/*.test-fixtures.*'
|
||||
- '**/__fixtures__/**'
|
||||
- 'src/shared/agent-launch/startup/claude-chat-entrypoint.ts'
|
||||
- 'src/main/claude/claude-stream-json-connection.ts'
|
||||
- 'src/main/claude/claude-agent-sdk-process-spawn.ts'
|
||||
- 'src/main/claude/structured/launch/claude-structured-child-env.ts'
|
||||
- 'src/main/claude/claude-model-catalog-probe.ts'
|
||||
rule:
|
||||
all:
|
||||
- any:
|
||||
- kind: string_fragment
|
||||
- kind: property_identifier
|
||||
- kind: identifier
|
||||
- regex: '^withOrcaClaudeChatEntrypoint$'
|
||||
---
|
||||
id: claude-chat-entrypoint-callers-tsx
|
||||
language: tsx
|
||||
severity: error
|
||||
message: Only structured native chat and its own probes may apply the chat identity.
|
||||
files: ['src/**']
|
||||
ignores:
|
||||
- '**/*.test.*'
|
||||
- '**/*.test-fixtures.*'
|
||||
- '**/__fixtures__/**'
|
||||
- 'src/shared/agent-launch/startup/claude-chat-entrypoint.ts'
|
||||
- 'src/main/claude/claude-stream-json-connection.ts'
|
||||
- 'src/main/claude/claude-agent-sdk-process-spawn.ts'
|
||||
- 'src/main/claude/structured/launch/claude-structured-child-env.ts'
|
||||
- 'src/main/claude/claude-model-catalog-probe.ts'
|
||||
rule:
|
||||
all:
|
||||
- any:
|
||||
- kind: string_fragment
|
||||
- kind: property_identifier
|
||||
- kind: identifier
|
||||
- regex: '^withOrcaClaudeChatEntrypoint$'
|
||||
---
|
||||
id: claude-entrypoint-key-owner
|
||||
language: typescript
|
||||
severity: error
|
||||
message: Only the chat identity owner and inherited-session isolation may access this key directly.
|
||||
files: ['src/**']
|
||||
ignores:
|
||||
- '**/*.test.*'
|
||||
- '**/*.test-fixtures.*'
|
||||
- '**/__fixtures__/**'
|
||||
- 'src/shared/agent-launch/startup/claude-chat-entrypoint.ts'
|
||||
- 'src/shared/agent-launch/startup/claude-parent-session-env.ts'
|
||||
rule:
|
||||
all:
|
||||
- any:
|
||||
- kind: string_fragment
|
||||
- kind: property_identifier
|
||||
- kind: identifier
|
||||
- regex: '^CLAUDE_ENTRYPOINT_ENV$'
|
||||
---
|
||||
id: claude-entrypoint-key-owner-tsx
|
||||
language: tsx
|
||||
severity: error
|
||||
message: Only the chat identity owner and inherited-session isolation may access this key directly.
|
||||
files: ['src/**']
|
||||
ignores:
|
||||
- '**/*.test.*'
|
||||
- '**/*.test-fixtures.*'
|
||||
- '**/__fixtures__/**'
|
||||
- 'src/shared/agent-launch/startup/claude-chat-entrypoint.ts'
|
||||
- 'src/shared/agent-launch/startup/claude-parent-session-env.ts'
|
||||
rule:
|
||||
all:
|
||||
- any:
|
||||
- kind: string_fragment
|
||||
- kind: property_identifier
|
||||
- kind: identifier
|
||||
- regex: '^CLAUDE_ENTRYPOINT_ENV$'
|
||||
@@ -0,0 +1,36 @@
|
||||
import { readFileSync } from 'node:fs'
|
||||
import { resolve } from 'node:path'
|
||||
import { fileURLToPath } from 'node:url'
|
||||
|
||||
// Why: import.meta.url, not dirname — electron-vite's config bundle rewrites only the former.
|
||||
const REPO_ROOT = fileURLToPath(new URL('../..', import.meta.url))
|
||||
|
||||
export const UNCOMPILED_LIST = 'config/react-compiler-uncompiled-files.txt'
|
||||
// Hand-kept list plus every file still in a hazard ratchet; compiled, these would run differently.
|
||||
export const UNCOMPILED_FILE_LISTS = [
|
||||
UNCOMPILED_LIST,
|
||||
'config/render-path-translate-baseline.txt',
|
||||
'config/react-compiler-hazard-baseline.txt'
|
||||
]
|
||||
|
||||
/** Repo-relative paths from a list or count baseline: `[count ]path[#detail][ # note]`. */
|
||||
export function parseListedFiles(text) {
|
||||
return text
|
||||
.split('\n')
|
||||
.map((line) => line.trim())
|
||||
.filter((line) => line && !line.startsWith('#'))
|
||||
.map((line) =>
|
||||
line
|
||||
.replace(/^\d+\s+/, '')
|
||||
.split('#')[0]
|
||||
.trim()
|
||||
)
|
||||
}
|
||||
|
||||
export function readListedFiles(list, root = REPO_ROOT) {
|
||||
return parseListedFiles(readFileSync(resolve(root, list), 'utf8'))
|
||||
}
|
||||
|
||||
export function reactCompilerExcludedFiles(root = REPO_ROOT) {
|
||||
return [...new Set(UNCOMPILED_FILE_LISTS.flatMap((list) => readListedFiles(list, root)))]
|
||||
}
|
||||
@@ -1,25 +1,5 @@
|
||||
import { readFileSync } from 'node:fs'
|
||||
import { resolve } from 'node:path'
|
||||
import type { Options } from '@vitejs/plugin-react'
|
||||
|
||||
// Hand-kept list plus every file still in a hazard ratchet; compiled, these would run differently.
|
||||
const UNCOMPILED_FILE_LISTS = [
|
||||
'config/react-compiler-uncompiled-files.txt',
|
||||
'config/render-path-translate-baseline.txt',
|
||||
'config/react-compiler-hazard-baseline.txt'
|
||||
]
|
||||
|
||||
function listedFiles(list: string): string[] {
|
||||
return readFileSync(resolve(list), 'utf8')
|
||||
.split('\n')
|
||||
.map((line) => line.trim())
|
||||
.filter((line) => line && !line.startsWith('#'))
|
||||
.map((line) => line.replace(/^\d+\s+/, '').split('#')[0])
|
||||
}
|
||||
|
||||
export function reactCompilerExcludedFiles(): string[] {
|
||||
return [...new Set(UNCOMPILED_FILE_LISTS.flatMap(listedFiles))]
|
||||
}
|
||||
import { reactCompilerExcludedFiles } from './react-compiler-uncompiled-files.mjs'
|
||||
|
||||
export function isReactCompilerEnabled(): boolean {
|
||||
return process.env.ORCA_REACT_COMPILER !== '0'
|
||||
|
||||
@@ -30,8 +30,6 @@
|
||||
3 test-no-in-test-import-actual:src/renderer/src/components/terminal-pane/snapshots/remote-snapshot-alt-screen-host-chain.test.ts
|
||||
1 test-no-in-test-import-actual:src/renderer/src/hooks/useIpcEvents-agent-status-pane-teardown.test.ts
|
||||
1 test-no-in-test-import-actual:src/renderer/src/hooks/useIpcEvents-agent-status-snapshot-hydration.test.ts
|
||||
1 test-no-in-test-import-actual:src/renderer/src/hooks/useIpcEvents-rate-limit-hydration.test.ts
|
||||
1 test-no-in-test-import-actual:src/renderer/src/lib/agent-session/launch/new-tab/agent-launch-caller-routing.test.ts
|
||||
1 test-no-polling-loop:src/main/browser/cookies/browser-cookie-import-concurrency.test.ts
|
||||
1 test-no-polling-loop:src/main/claude/claude-stop-ack-race.test.ts
|
||||
1 test-no-polling-loop:src/main/claude/claude-stream-json-connection.test.ts
|
||||
@@ -257,14 +255,12 @@
|
||||
1 test-no-real-time-wait:src/main/windows/windows-process-tree-command-line-patch.test.ts
|
||||
2 test-no-real-time-wait:src/main/windows/windows-pty-job.win32.test.ts
|
||||
1 test-no-real-time-wait:src/main/worker-thread-child-process/worker-thread-child-process.test.ts
|
||||
1 test-no-real-time-wait:src/main/workspaces/creation/preparation/worktree-create-preparation-cancellation.test.ts
|
||||
1 test-no-real-time-wait:src/main/workspaces/removal/local-worktree-removal-recovery-live.test.ts
|
||||
2 test-no-real-time-wait:src/main/wsl/execution/wsl-command-loop.test.ts
|
||||
2 test-no-real-time-wait:src/main/wsl/orcad/wsl-orcad-real-distro-lane.test.ts
|
||||
4 test-no-real-time-wait:src/renderer/src/components/activity/activity-auto-mark-read-loop.react185.test.tsx
|
||||
1 test-no-real-time-wait:src/renderer/src/components/editor/DiagramViewerModal.test.tsx
|
||||
1 test-no-real-time-wait:src/renderer/src/components/editor/combined-diff/load-sections/combined-diff-stale-analysis-work-budget.test.tsx
|
||||
1 test-no-real-time-wait:src/renderer/src/components/native-chat/drafts/native-chat-composer-draft-lifecycle.test.tsx
|
||||
4 test-no-real-time-wait:src/renderer/src/components/native-chat/drafts/native-chat-composer-draft-store.test.ts
|
||||
1 test-no-real-time-wait:src/renderer/src/components/terminal-pane/layout/split/resolve-split-cwd.test.ts
|
||||
2 test-no-real-time-wait:src/renderer/src/components/terminal-pane/pty-connection/emulation/fish-color-scheme-child-stdin.node-pty.test.ts
|
||||
@@ -274,7 +270,6 @@
|
||||
1 test-no-real-time-wait:src/renderer/src/components/terminal-pane/viewport/terminal-fit-restore.test.ts
|
||||
1 test-no-real-time-wait:src/renderer/src/hooks/runtime-project-refresh-scheduler.test.ts
|
||||
1 test-no-real-time-wait:src/renderer/src/lib/agent-session/resume/cli-fork/native-chat-cli-fork-preparation.test.ts
|
||||
1 test-no-real-time-wait:src/renderer/src/lib/orca-yaml-trust-prompt-slot-eviction.test.ts
|
||||
2 test-no-real-time-wait:src/renderer/src/store/slices/workspace-cleanup/workspace-cleanup-removal-preflight.test.ts
|
||||
2 test-no-real-time-wait:src/shared/__tests__/process-host/windows-tree-kill-late-taskkill.win32.test.ts
|
||||
1 test-no-real-time-wait:src/shared/darwin-process-table-capture.test.ts
|
||||
@@ -634,12 +629,12 @@
|
||||
2 test-no-wall-clock:src/renderer/src/components/dashboard/useLiveDashboardSnapshot.test.ts
|
||||
1 test-no-wall-clock:src/renderer/src/components/native-chat/conversation/slots/NativeChatMessageList.opening-send.test.tsx
|
||||
1 test-no-wall-clock:src/renderer/src/components/native-chat/conversation/slots/NativeChatMessageList.queued-turn-order.test.tsx
|
||||
3 test-no-wall-clock:src/renderer/src/components/native-chat/conversation/turns/NativeChatMessageList.turn-indicator.test.tsx
|
||||
2 test-no-wall-clock:src/renderer/src/components/native-chat/conversation/turns/NativeChatMessageList.turn-indicator.test.tsx
|
||||
3 test-no-wall-clock:src/renderer/src/components/native-chat/conversation/turns/NativeChatResolvedView.turn-status.test.tsx
|
||||
1 test-no-wall-clock:src/renderer/src/components/native-chat/session/structured/delivery/NativeChatMessageList.unsent-message.test.tsx
|
||||
3 test-no-wall-clock:src/renderer/src/components/native-chat/surfaces/integration/NativeChatMessageList.test.tsx
|
||||
2 test-no-wall-clock:src/renderer/src/components/native-chat/tools/tasks/NativeChatStructuredSessionStatus.test.tsx
|
||||
3 test-no-wall-clock:src/renderer/src/components/sidebar/workspace-card/review/use-workspace-reference-details.test.tsx
|
||||
1 test-no-wall-clock:src/renderer/src/components/sidebar/workspace-card/review/use-workspace-reference-details.test.tsx
|
||||
1 test-no-wall-clock:src/renderer/src/components/sidebar/worktree-list/listing/WorktreeList.lineage-agent-expansion-coupling.test.tsx
|
||||
2 test-no-wall-clock:src/renderer/src/components/task-page/jira/task-page-jira-cache-selectors.test.ts
|
||||
2 test-no-wall-clock:src/renderer/src/components/terminal-pane/pty-connection/emulation/fish-color-scheme-child-stdin.node-pty.test.ts
|
||||
@@ -649,13 +644,11 @@
|
||||
1 test-no-wall-clock:src/renderer/src/components/worktree-jump/WorktreeJumpPalette.recent-tabs.behavior.test.tsx
|
||||
4 test-no-wall-clock:src/renderer/src/components/worktree-jump/WorktreeJumpPalette.recent-tabs.test.tsx
|
||||
2 test-no-wall-clock:src/renderer/src/hooks/ipc-events/agent-status-terminal-title-tab-write.test.ts
|
||||
1 test-no-wall-clock:src/renderer/src/hooks/useIpcEvents-agent-status-hook-titles.test.ts
|
||||
1 test-no-wall-clock:src/renderer/src/lib/paired-runtime-closed-tab-resume.test.ts
|
||||
2 test-no-wall-clock:src/renderer/src/lib/use-tab-agent-observed-signal-dispatch.test.tsx
|
||||
2 test-no-wall-clock:src/renderer/src/lib/wake-sleeping-agents-live-unmounted-pane.test.ts
|
||||
1 test-no-wall-clock:src/renderer/src/lib/workspace/ownership/workspace-terminal-host-authority.test.ts
|
||||
1 test-no-wall-clock:src/renderer/src/lib/workspace/activation/worktree-activation-emptied-workspace-reseed.test.ts
|
||||
2 test-no-wall-clock:src/renderer/src/runtime/native-chat/tab-retirement/structured-agent-session-tab-retirement.test.ts
|
||||
2 test-no-wall-clock:src/renderer/src/store/github/pull-requests/github-pr-branch-linked-pr-divergence.test.ts
|
||||
6 test-no-wall-clock:src/renderer/src/store/slices/jira/jira.test.ts
|
||||
5 test-no-wall-clock:src/renderer/src/store/slices/worktrees/metadata/worktree-meta-hosted-review.test.ts
|
||||
@@ -679,7 +672,6 @@
|
||||
2 test-no-wall-clock:tests/e2e/cross-version-wire/release-source-retention.unit.test.ts
|
||||
1 test-no-wall-clock:tests/e2e/host-cold-park-remote-subscriber.unit.test.ts
|
||||
2 test-no-wall-clock:tests/e2e/omp-child-session-recovery.unit.test.ts
|
||||
1 test-no-wall-clock:tests/e2e/structured-session-tab-close-regressions.unit.test.ts
|
||||
2 test-timeout-needs-reason:mobile/src/terminal/document/native-document-bundle.test.ts
|
||||
1 test-timeout-needs-reason:mobile/src/test-support/rpc-recording/family-recordings.test.ts
|
||||
1 test-timeout-needs-reason:mobile/src/test-support/rpc-recording/mutants/family-mutants.test.ts
|
||||
|
||||
@@ -12,17 +12,17 @@
|
||||
3 src/renderer/src/components/LinearIssueTextEditor.tsx
|
||||
3 src/renderer/src/components/LinearIssueWorkspace.tsx
|
||||
5 src/renderer/src/components/LinearItemDrawer.tsx
|
||||
1 src/renderer/src/components/NativeChatResumeOnRestartGroups.tsx
|
||||
1 src/renderer/src/components/native-chat-recovery/tree/NativeChatResumeOnRestartGroups.tsx
|
||||
1 src/renderer/src/components/activity/ActivityPrototypePage.tsx
|
||||
1 src/renderer/src/components/activity/activity-scope-filter-controls.tsx
|
||||
2 src/renderer/src/components/activity/activity-thread-actions.ts
|
||||
1 src/renderer/src/components/activity/use-agent-pane-thread-store-data.ts
|
||||
1 src/renderer/src/components/activity/use-agent-pane-threads.ts
|
||||
4 src/renderer/src/components/agent/AgentSettingsDialog.tsx
|
||||
1 src/renderer/src/components/automations/automation-host-client.ts
|
||||
1 src/renderer/src/components/automations/hosts/automation-host-client.ts
|
||||
1 src/renderer/src/components/automations/automations-page-fixtures.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-controller.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-destination-form.ts
|
||||
1 src/renderer/src/components/automations/authoring/use-automations-page-destination-form.ts
|
||||
1 src/renderer/src/components/browser-pane/ReopenBrowserPageOnServerButton.tsx
|
||||
1 src/renderer/src/components/browser-pane/browser-reopen-on-server.ts
|
||||
1 src/renderer/src/components/browser-pane/stream-remote/use-remote-browser-page-stream.ts
|
||||
@@ -204,11 +204,11 @@
|
||||
1 src/renderer/src/hooks/ipc-events/runtime-environment-subscription-selection.ts
|
||||
1 src/renderer/src/hooks/ipc-events/settings-sidebar-ipc-bridge.ts
|
||||
1 src/renderer/src/hooks/ipc-events/terminal-request-ipc-bridge.ts
|
||||
1 src/renderer/src/hooks/use-active-skill-discovery-runtime-target.ts
|
||||
1 src/renderer/src/hooks/skills/discovery/use-active-skill-discovery-runtime-target.ts
|
||||
2 src/renderer/src/hooks/use-integration-provider-status-refresh.ts
|
||||
1 src/renderer/src/hooks/useActiveProjectSkillRuntime.ts
|
||||
1 src/renderer/src/hooks/skills/runtime/useActiveProjectSkillRuntime.ts
|
||||
1 src/renderer/src/hooks/useEditorExternalWatch.ts
|
||||
1 src/renderer/src/hooks/useInstalledAgentSkills.ts
|
||||
1 src/renderer/src/hooks/skills/discovery/useInstalledAgentSkills.ts
|
||||
1 src/renderer/src/hooks/useIpcEvents.ts
|
||||
4 src/renderer/src/hooks/useIssueMetadata.ts
|
||||
2 src/renderer/src/hooks/useLinearIssuePublication.ts
|
||||
@@ -230,11 +230,11 @@
|
||||
1 src/renderer/src/lib/workspace/ownership/runtime-session-mirror-owners.ts
|
||||
1 src/renderer/src/lib/runtime-session-mirror-targets.ts
|
||||
1 src/renderer/src/lib/workspace/ownership/single-runtime-legacy-owner.ts
|
||||
1 src/renderer/src/lib/skill-runtime-command.ts
|
||||
1 src/renderer/src/lib/terminal-close-route.ts
|
||||
4 src/renderer/src/lib/terminal-worktree-route.ts # resolveTerminalPtyOwner: teardown, close and PTY identity read spawn's attribution (round 3 F8), which retired the deprecated resolver's readers
|
||||
1 src/renderer/src/lib/skills/runtime/skill-runtime-command.ts
|
||||
1 src/renderer/src/lib/workspace/ownership/terminal-close-route.ts
|
||||
4 src/renderer/src/lib/workspace/ownership/terminal-worktree-route.ts # resolveTerminalPtyOwner: teardown, close and PTY identity read spawn's attribution (round 3 F8), which retired the deprecated resolver's readers
|
||||
3 src/renderer/src/lib/unread-badge-count-selector.ts
|
||||
1 src/renderer/src/lib/web-runtime-worktree-terminal-after-wake.ts
|
||||
1 src/renderer/src/runtime/hosted-terminals/restoration/web-runtime-worktree-terminal-after-wake.ts
|
||||
1 src/renderer/src/lib/work-items/linear/linear-issue-url-lookup.ts
|
||||
1 src/renderer/src/lib/work-items/linear/linear-issue-write.ts
|
||||
1 src/renderer/src/lib/workspace/activation/worktree-activation.ts
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# JSX mapped straight over a host collection, per file, outside components/host-picker.
|
||||
# This is a RATCHET: counts may only go DOWN. Draw host lists with HostCombobox or
|
||||
# useBoundedHostRows. Prune after a fix: pnpm check:host-list-render-ratchet --prune
|
||||
1 src/renderer/src/components/automations/AutomationRunsDashboard.tsx
|
||||
1 src/renderer/src/components/automations/runs/AutomationRunsDashboard.tsx
|
||||
1 src/renderer/src/components/right-sidebar/ai-vault/panel/AiVaultPanelControls.tsx
|
||||
1 src/renderer/src/components/right-sidebar/source-control/ai/SourceControlAgentActionDialogForm.tsx
|
||||
1 src/renderer/src/components/settings/browser/profiles/BrowserSessionCookiesSection.tsx
|
||||
|
||||
@@ -3,9 +3,10 @@
|
||||
# This is a RATCHET: counts may only go DOWN. Layout moves to one runtime owner; do not add
|
||||
# writers. Prune after removing writers: pnpm check:layout-writer-ratchets --prune
|
||||
1 src/main/ipc/pty/ipc/leaf-move.ts
|
||||
1 src/main/ipc/pty/pane/fresh-pane-binding.ts
|
||||
1 src/main/ipc/pty/pane/pane-owner-replacement.ts
|
||||
3 src/main/ipc/pty/pane/stable-owner.ts
|
||||
2 src/main/ipc/pty/spawn-commit-binding.ts
|
||||
1 src/main/ipc/pty/spawn-commit-binding.ts
|
||||
1 src/main/ipc/renderer-shutdown-checkpoint.ts
|
||||
1 src/main/ipc/runtime-environments/runtime-environment-removal-cleanup.ts
|
||||
1 src/main/ipc/runtime-environments/runtime-environment-session-reconcile.ts
|
||||
@@ -32,6 +33,7 @@
|
||||
2 src/main/persistence/migrating-orcad-catalog/orcad-destination-client-state.ts
|
||||
1 src/main/persistence/migrating-orcad-catalog/orcad-destination-workspace-session.ts
|
||||
3 src/main/persistence/migrating-orcad-catalog/orcad-dormant-state-records.ts
|
||||
1 src/main/persistence/migrating-orcad-catalog/orcad-migration-source-retention.ts
|
||||
2 src/main/persistence/migrating-orcad-catalog/orcad-source-client-subtraction.ts
|
||||
1 src/main/persistence/migrating-orcad-catalog/orcad-source-dormant-state.ts
|
||||
1 src/main/persistence/migrating-orcad-catalog/orcad-source-scrollback-state.ts
|
||||
@@ -53,11 +55,11 @@
|
||||
2 src/main/pty/scrollback/terminal-scrollback-snapshots.ts
|
||||
1 src/main/runtime/browser/client-pages/client-hosted-browser-page-persistence.ts
|
||||
1 src/main/runtime/client/runtime-client-state.ts
|
||||
1 src/main/runtime/session-tabs/headless-editor-tabs.ts
|
||||
4 src/main/runtime/orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-persistence.ts
|
||||
2 src/main/runtime/session-graph/session-graph-promotion.ts
|
||||
2 src/main/runtime/session-lifecycle/projection/apply-mobile-session-tab-navigation.ts
|
||||
2 src/main/runtime/session-lifecycle/projection/build-headless-mobile-session-browser-tabs.ts
|
||||
1 src/main/runtime/session-tabs/headless-editor-tabs.ts
|
||||
2 src/main/runtime/session-tabs/headless-tab-group-moves.ts
|
||||
6 src/main/runtime/session-tabs/headless-tab-properties.ts
|
||||
2 src/main/runtime/session-tabs/headless-terminal-tab-titles.ts
|
||||
@@ -72,5 +74,4 @@
|
||||
3 src/main/runtime/terminal/surface/mobile-session-layout-projection.ts
|
||||
1 src/main/runtime/workspaces/session-hosts/get-runtime-id.ts
|
||||
1 src/main/runtime/workspaces/session-hosts/runtime-workspace-session-controller.ts
|
||||
1 src/main/persistence/migrating-orcad-catalog/orcad-migration-source-retention.ts
|
||||
1 src/main/ssh/targets/ssh-target-id-migration.ts
|
||||
|
||||
@@ -282,6 +282,7 @@
|
||||
1 src/main/ipc/filesystem/watcher-process/parcel-watcher-supervisor-subscribe.ts
|
||||
1 src/main/ipc/filesystem/watcher-process/rebinding-file-watch.ts
|
||||
1 src/main/ipc/filesystem/watcher-process/watcher-event-root-path-rewrite.ts
|
||||
1 src/main/ipc/floating-workspace-directory.ts
|
||||
1 src/main/ipc/macos-keyboard-layout-snapshot.ts
|
||||
1 src/main/ipc/notification-authorization-status.ts
|
||||
1 src/main/ipc/pty/spawn-pane-env.ts
|
||||
@@ -550,7 +551,6 @@
|
||||
2 src/main/worker-threads/forked-child-entry-path.ts
|
||||
4 src/main/workspace-hooks/hooks.ts
|
||||
10 src/main/workspace-hooks/issue-command-file.ts
|
||||
4 src/main/workspace-hooks/worktree-runner-script.ts
|
||||
1 src/main/workspaces/catalog/folder-repo-git-conversion.ts
|
||||
2 src/main/workspaces/catalog/folder-upgrade-worktree-path.ts
|
||||
3 src/main/workspaces/execution-host/project-runtime-git-router.ts
|
||||
|
||||
@@ -307,6 +307,27 @@
|
||||
"dynamic": false,
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/terminal/session/MobileSessionLatchKeys.tsx",
|
||||
"kind": "object-property:label",
|
||||
"text": "Shift",
|
||||
"dynamic": false,
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/terminal/session/MobileSessionLatchKeys.tsx",
|
||||
"kind": "object-property:label",
|
||||
"text": "Ctrl",
|
||||
"dynamic": false,
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/terminal/session/MobileSessionLatchKeys.tsx",
|
||||
"kind": "object-property:label",
|
||||
"text": "Alt",
|
||||
"dynamic": false,
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/tasks/mobile-smart-source-modes.ts",
|
||||
"kind": "object-property:label",
|
||||
@@ -539,21 +560,21 @@
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/transport/hosts/mobile-relay-host-overlay.ts",
|
||||
"filePath": "mobile/src/host-catalog/mobile-relay-host-overlay.ts",
|
||||
"kind": "object-property:message",
|
||||
"text": "Expected exactly one endpoint for configured relay metadata",
|
||||
"dynamic": false,
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/transport/hosts/mobile-relay-host-overlay.ts",
|
||||
"filePath": "mobile/src/host-catalog/mobile-relay-host-overlay.ts",
|
||||
"kind": "object-property:message",
|
||||
"text": "Relay host identity mismatch",
|
||||
"dynamic": false,
|
||||
"count": 1
|
||||
},
|
||||
{
|
||||
"filePath": "mobile/src/transport/hosts/mobile-relay-host-overlay.ts",
|
||||
"filePath": "mobile/src/host-catalog/mobile-relay-host-overlay.ts",
|
||||
"kind": "object-property:message",
|
||||
"text": "Relay identity and endpoint must coexist",
|
||||
"dynamic": false,
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
"import/export": "warn",
|
||||
"import/named": "warn",
|
||||
"import/namespace": "warn",
|
||||
"import/no-cycle": ["warn", { "maxDepth": 3 }],
|
||||
"import/no-cycle": ["warn", { "ignoreTypes": true }],
|
||||
"import/no-duplicates": "warn",
|
||||
"import/no-empty-named-blocks": "warn",
|
||||
"import/no-self-import": "warn"
|
||||
|
||||
@@ -28,27 +28,27 @@
|
||||
1 src/renderer/src/components/artifacts/ArtifactPublishButton.tsx
|
||||
2 src/renderer/src/components/artifacts/ArtifactsPage.tsx
|
||||
2 src/renderer/src/components/artifacts/useArtifactPagination.ts
|
||||
2 src/renderer/src/components/automations/AutomationEditorPromptEditor.tsx
|
||||
1 src/renderer/src/components/automations/AutomationHostFilterNotice.tsx
|
||||
1 src/renderer/src/components/automations/AutomationProjectCombobox.tsx
|
||||
1 src/renderer/src/components/automations/AutomationRunHistory.tsx
|
||||
1 src/renderer/src/components/automations/AutomationRunsDashboard.tsx
|
||||
1 src/renderer/src/components/automations/AutomationRunsTable.tsx
|
||||
2 src/renderer/src/components/automations/authoring/AutomationEditorPromptEditor.tsx
|
||||
1 src/renderer/src/components/automations/hosts/AutomationHostFilterNotice.tsx
|
||||
1 src/renderer/src/components/automations/authoring/AutomationProjectCombobox.tsx
|
||||
1 src/renderer/src/components/automations/runs/AutomationRunHistory.tsx
|
||||
1 src/renderer/src/components/automations/runs/AutomationRunsDashboard.tsx
|
||||
1 src/renderer/src/components/automations/runs/AutomationRunsTable.tsx
|
||||
1 src/renderer/src/components/automations/AutomationsPageSurface.tsx
|
||||
1 src/renderer/src/components/automations/use-automation-agent-picker-entries.ts
|
||||
2 src/renderer/src/components/automations/use-automation-create-destination.ts
|
||||
4 src/renderer/src/components/automations/use-automation-host-catalog.ts
|
||||
4 src/renderer/src/components/automations/use-automation-list-search.ts
|
||||
2 src/renderer/src/components/automations/use-automation-migrate-action.ts
|
||||
1 src/renderer/src/components/automations/use-automation-runs-dashboard.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-list-state.ts
|
||||
1 src/renderer/src/components/automations/authoring/use-automation-agent-picker-entries.ts
|
||||
2 src/renderer/src/components/automations/authoring/use-automation-create-destination.ts
|
||||
4 src/renderer/src/components/automations/hosts/use-automation-host-catalog.ts
|
||||
4 src/renderer/src/components/automations/listing/use-automation-list-search.ts
|
||||
2 src/renderer/src/components/automations/authoring/use-automation-migrate-action.ts
|
||||
1 src/renderer/src/components/automations/runs/use-automation-runs-dashboard.ts
|
||||
1 src/renderer/src/components/automations/listing/use-automations-page-list-state.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-local-state.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-refresh.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-setup-state.ts
|
||||
1 src/renderer/src/components/automations/authoring/use-automations-page-setup-state.ts
|
||||
1 src/renderer/src/components/automations/use-automations-page-store-state.ts
|
||||
1 src/renderer/src/components/automations/use-external-automation-scope-retention.ts
|
||||
2 src/renderer/src/components/automations/use-scoped-external-automations.ts
|
||||
16 src/renderer/src/components/automations/use-selected-automation-run-history.ts
|
||||
1 src/renderer/src/components/automations/external/use-external-automation-scope-retention.ts
|
||||
2 src/renderer/src/components/automations/external/use-scoped-external-automations.ts
|
||||
16 src/renderer/src/components/automations/runs/use-selected-automation-run-history.ts
|
||||
7 src/renderer/src/components/browser-extension-install-dialog.tsx
|
||||
1 src/renderer/src/components/browser-pane/ClientHostedBrowserPagePane.tsx
|
||||
2 src/renderer/src/components/browser-pane/annotate/MarkupOverlay.tsx
|
||||
@@ -206,7 +206,7 @@
|
||||
1 src/renderer/src/components/mobile/WindowsFirewallNotice.tsx
|
||||
2 src/renderer/src/components/mobile/use-mobile-page-paired-devices.ts
|
||||
1 src/renderer/src/components/mobile/use-mobile-pairing-generation.ts
|
||||
1 src/renderer/src/components/native-chat-restart-runtimes.ts
|
||||
1 src/renderer/src/components/native-chat-recovery/offers/native-chat-restart-runtimes.ts
|
||||
1 src/renderer/src/components/native-chat/NativeChatStructuredSession.tsx
|
||||
8 src/renderer/src/components/native-chat/attachments/chips/use-native-chat-composer-attachments.ts
|
||||
2 src/renderer/src/components/native-chat/attachments/intake/use-native-chat-resolved-path-attachments.ts
|
||||
@@ -542,16 +542,16 @@
|
||||
4 src/renderer/src/components/sidebar/worktree-list/viewport/use-row-measurement.ts
|
||||
1 src/renderer/src/components/sidebar/worktree-list/viewport/use-scroll-to-top.ts
|
||||
1 src/renderer/src/components/sidebar/worktree-list/viewport/use-virtualizer.ts
|
||||
1 src/renderer/src/components/skills/SkillBundleInstallFlow.tsx
|
||||
2 src/renderer/src/components/skills/SkillInstallDialog.tsx
|
||||
4 src/renderer/src/components/skills/SkillInstallManagementDialog.tsx
|
||||
1 src/renderer/src/components/skills/SkillShareDialog.tsx
|
||||
1 src/renderer/src/components/skills/SkillSharedLinkRow.tsx
|
||||
1 src/renderer/src/components/skills/installation/SkillBundleInstallFlow.tsx
|
||||
2 src/renderer/src/components/skills/installation/SkillInstallDialog.tsx
|
||||
4 src/renderer/src/components/skills/installation/SkillInstallManagementDialog.tsx
|
||||
1 src/renderer/src/components/skills/sharing/SkillShareDialog.tsx
|
||||
1 src/renderer/src/components/skills/sharing/SkillSharedLinkRow.tsx
|
||||
1 src/renderer/src/components/skills/SkillsPage.tsx
|
||||
1 src/renderer/src/components/skills/setup/WslAgentSkillSetupPanel.tsx
|
||||
2 src/renderer/src/components/skills/use-owned-skill-shares.ts
|
||||
1 src/renderer/src/components/skills/use-reviewed-skill-plan.ts
|
||||
1 src/renderer/src/components/skills/use-skill-delete-flow.ts
|
||||
2 src/renderer/src/components/skills/sharing/use-owned-skill-shares.ts
|
||||
1 src/renderer/src/components/skills/freshness/use-reviewed-skill-plan.ts
|
||||
1 src/renderer/src/components/skills/deletion/use-skill-delete-flow.ts
|
||||
1 src/renderer/src/components/sparse/SparseCheckoutPresetSelect.tsx
|
||||
1 src/renderer/src/components/ssh-host-recovery/SshHostMoveAnywayAction.tsx
|
||||
2 src/renderer/src/components/star-nag/StarNagAgentValueMomentObserver.tsx
|
||||
@@ -651,7 +651,7 @@
|
||||
2 src/renderer/src/components/terminal-pane/mobile-driver/MobileDriverOverlay.tsx
|
||||
1 src/renderer/src/components/terminal-pane/mobile-driver/TerminalPaneMobileDriverPortals.tsx
|
||||
1 src/renderer/src/components/terminal-pane/mounting/use-terminal-pane-mount-lifecycle.ts
|
||||
2 src/renderer/src/components/terminal-pane/parking/lifecycle/use-terminal-tab-cold-parking.ts
|
||||
1 src/renderer/src/components/terminal-pane/parking/lifecycle/use-terminal-tab-cold-parking.ts
|
||||
1 src/renderer/src/components/terminal-pane/parking/retention/terminal-pending-startup-park-presence.ts
|
||||
1 src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/recovery/TerminalPaneRecoveryPortals.tsx
|
||||
2 src/renderer/src/components/terminal-pane/session-fork/TerminalAgentSessionForkDialog.tsx
|
||||
@@ -693,21 +693,21 @@
|
||||
1 src/renderer/src/hooks/composer-state/workspace-identity-state.ts
|
||||
3 src/renderer/src/hooks/linear-issue-committed-state.ts
|
||||
1 src/renderer/src/hooks/use-audio-capture.ts
|
||||
1 src/renderer/src/hooks/use-bundled-skill-install.ts
|
||||
1 src/renderer/src/hooks/skills/installation/use-bundled-skill-install.ts
|
||||
2 src/renderer/src/hooks/useDetectedAgents.ts
|
||||
2 src/renderer/src/hooks/useGitHubTaskItems.ts
|
||||
2 src/renderer/src/hooks/useImmediateMutation.ts
|
||||
6 src/renderer/src/hooks/useInstalledAgentSkills.ts
|
||||
6 src/renderer/src/hooks/skills/discovery/useInstalledAgentSkills.ts
|
||||
1 src/renderer/src/hooks/useIssueMetadata.ts
|
||||
3 src/renderer/src/hooks/useLinearIssuePublication.ts
|
||||
1 src/renderer/src/hooks/useMacTccAttributionSeveredNotice.ts
|
||||
1 src/renderer/src/hooks/useSettingsNavigationMetadata.ts
|
||||
4 src/renderer/src/hooks/useSkillFreshness.ts
|
||||
4 src/renderer/src/hooks/skills/freshness/useSkillFreshness.ts
|
||||
1 src/renderer/src/hooks/useTaskPageGitHubWorkItemMutation.ts
|
||||
6 src/renderer/src/hooks/useVirtualizedScrollAnchor.ts
|
||||
1 src/renderer/src/lib/host-chat-program-acquisition.ts
|
||||
1 src/renderer/src/lib/quick-open-file-history.ts
|
||||
2 src/renderer/src/lib/worker-auto-close.ts
|
||||
1 src/renderer/src/lib/agent-session/launch/inventory/host-chat-program-acquisition.ts
|
||||
1 src/renderer/src/lib/files/search/quick-open-file-history.ts
|
||||
2 src/renderer/src/runtime/agent-orchestration/worker-auto-close.ts
|
||||
1 src/renderer/src/runtime/native-chat/naming/structured-chat-name-observation.ts
|
||||
1 src/renderer/src/store/plugins/appearance/plugin-icon-themes.ts
|
||||
5 src/renderer/src/store/retained-views/app-state-view.ts
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# Grandfathered code React Compiler would run differently (<file>#<function>:<hazard>).
|
||||
# Generated; never hand-edit. Lower after a fix: pnpm check:react-compiler-compat-ratchet --prune
|
||||
1 src/renderer/src/components/agent/agent-launch-picker-drafts.ts#useAgentPickerSetup:discarded-subscription
|
||||
1 src/renderer/src/components/native-chat-restart-runtimes.ts#useNativeChatRestartRuntimes:discarded-subscription
|
||||
1 src/renderer/src/components/native-chat-recovery/offers/native-chat-restart-runtimes.ts#useNativeChatRestartRuntimes:discarded-subscription
|
||||
1 src/renderer/src/components/right-sidebar/source-control/ai/use-source-control-action-agent-choice.ts#useSourceControlActionAgentChoice:store-read-in-memo-block
|
||||
|
||||
@@ -85,9 +85,9 @@
|
||||
1 src/renderer/src/components/terminal-pane/render-health/terminal-render-desync-sentinel.ts
|
||||
1 src/renderer/src/hooks/use-now.ts
|
||||
1 src/renderer/src/lib/agent-session/hibernation/agent-hibernation-coordinator.ts
|
||||
1 src/renderer/src/lib/crash-diagnostics.ts
|
||||
1 src/renderer/src/lib/window-visibility-interval.ts
|
||||
1 src/renderer/src/lib/worker-auto-close.ts
|
||||
1 src/renderer/src/diagnostics/crash-reporting/crash-diagnostics.ts
|
||||
1 src/renderer/src/lib/window-activity/window-visibility-interval.ts
|
||||
1 src/renderer/src/runtime/agent-orchestration/worker-auto-close.ts
|
||||
1 src/renderer/src/runtime/hosts/wsl/wsl-refused-read-watch.ts
|
||||
1 src/shared/remote-runtime/control/remote-runtime-shared-control-app-heartbeat.ts
|
||||
1 src/shared/remote-runtime/remote-runtime-socket-liveness.ts
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
# This is a RATCHET: counts may only go DOWN. Use useTranslate()/useIntlLocale() from
|
||||
# @/i18n/use-translate. Prune after a fix: pnpm check:render-path-translate-ratchet --prune
|
||||
2 src/renderer/src/components/agent/AgentLaunchPromptComposer.tsx
|
||||
5 src/renderer/src/components/automations/use-external-automation-actions.ts
|
||||
5 src/renderer/src/components/automations/external/use-external-automation-actions.ts
|
||||
1 src/renderer/src/components/diff-comments/useDiffCommentDecorator.tsx
|
||||
2 src/renderer/src/components/editor/markdown-preview/render-tree/use-markdown-preview-components.tsx
|
||||
1 src/renderer/src/components/tab-group/useTabGroupCreationCommands.ts
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
4 src/renderer/src/components/terminal-pane/render-health/recovery/terminal-recovery-ledger-test-store.ts
|
||||
3 src/renderer/src/components/worktree-jump/worktree-jump-palette-status-inputs.ts
|
||||
1 src/renderer/src/lib/agent-session/hibernation/agent-hibernation-coordinator.ts
|
||||
4 src/renderer/src/lib/floating-workspace-terminal-actions.ts
|
||||
4 src/renderer/src/components/floating-terminal/floating-workspace-terminal-actions.ts
|
||||
1 src/renderer/src/lib/pane-manager/client-hosted-browser-row-state.ts
|
||||
4 src/renderer/src/lib/workspace/persistence/session-write-subscriber.ts
|
||||
1 src/renderer/src/lib/workspace/persistence/workspace-session-browser-tabs.ts
|
||||
@@ -27,6 +27,7 @@
|
||||
3 src/renderer/src/lib/workspace/persistence/workspace-session-staged-browser-tabs.ts
|
||||
1 src/renderer/src/lib/workspace/persistence/workspace-session-unified-tabs.ts
|
||||
17 src/renderer/src/lib/workspace/persistence/workspace-session.ts
|
||||
13 src/renderer/src/runtime/browser/creation/testing/web-runtime-browser-creation-placement-test-rig.ts
|
||||
3 src/renderer/src/runtime/hosted-terminals/recovery/adoption/web-session-terminal-recovery-snapshot-validation.ts
|
||||
1 src/renderer/src/runtime/hosted-terminals/recovery/surfaces/web-session-terminal-orphan-recovery-surface.ts
|
||||
2 src/renderer/src/runtime/hosted-terminals/recovery/surfaces/web-session-terminal-orphan-topology.ts
|
||||
@@ -35,15 +36,14 @@
|
||||
10 src/renderer/src/runtime/sync-runtime-graph/mobile-session-group-projection.ts
|
||||
2 src/renderer/src/runtime/sync-runtime-graph/mobile-session-snapshots.ts
|
||||
2 src/renderer/src/runtime/sync-runtime-graph/sync-key.ts
|
||||
13 src/renderer/src/runtime/browser/creation/testing/web-runtime-browser-creation-placement-test-rig.ts
|
||||
1 src/renderer/src/runtime/web-session-tabs-sync/inventory/web-runtime-session-snapshot.ts
|
||||
3 src/renderer/src/runtime/web-session-tabs-sync/placement/web-session-client-owned-tab-placement.ts
|
||||
1 src/renderer/src/runtime/web-session-tabs-sync/agent-status-primitives.ts
|
||||
8 src/renderer/src/runtime/web-session-tabs-sync/apply-active-state.ts
|
||||
18 src/renderer/src/runtime/web-session-tabs-sync/apply-final-patch.ts
|
||||
2 src/renderer/src/runtime/web-session-tabs-sync/apply-preparation-groups.ts
|
||||
5 src/renderer/src/runtime/web-session-tabs-sync/apply-terminal-records.ts
|
||||
4 src/renderer/src/runtime/web-session-tabs-sync/apply-worktree-records.ts
|
||||
1 src/renderer/src/runtime/web-session-tabs-sync/inventory/web-runtime-session-snapshot.ts
|
||||
3 src/renderer/src/runtime/web-session-tabs-sync/placement/web-session-client-owned-tab-placement.ts
|
||||
2 src/renderer/src/runtime/web-session-tabs-sync/session-tabs-inventory-absence.ts
|
||||
10 src/renderer/src/store/slices/browser/cleanup/browser-close-actions.ts
|
||||
2 src/renderer/src/store/slices/browser/create-browser-slice.ts
|
||||
@@ -57,7 +57,7 @@
|
||||
9 src/renderer/src/store/slices/editor/checks/check-run-details-actions.ts
|
||||
6 src/renderer/src/store/slices/editor/closing/close-file-action.ts
|
||||
10 src/renderer/src/store/slices/editor/closing/recently-closed-editor-tabs.ts
|
||||
3 src/renderer/src/store/slices/editor/file-ids/hydrated-editor-file-ids.ts
|
||||
1 src/renderer/src/store/slices/editor/file-ids/hydrated-editor-file-ids.ts
|
||||
2 src/renderer/src/store/slices/editor/file-ids/hydrated-editor-file-selection.ts
|
||||
1 src/renderer/src/store/slices/editor/file-ids/open-file-path-rekey.ts
|
||||
2 src/renderer/src/store/slices/editor/file-ids/rekey-open-files-action.ts
|
||||
@@ -82,7 +82,7 @@
|
||||
4 src/renderer/src/store/slices/tabs/tab-group-state.ts
|
||||
9 src/renderer/src/store/slices/tabs/tabs-close-actions.ts
|
||||
14 src/renderer/src/store/slices/tabs/tabs-create-actions.ts
|
||||
23 src/renderer/src/store/slices/tabs/tabs-drag-preview-actions.ts
|
||||
22 src/renderer/src/store/slices/tabs/tabs-drag-preview-actions.ts
|
||||
11 src/renderer/src/store/slices/tabs/tabs-drop-actions.ts
|
||||
8 src/renderer/src/store/slices/tabs/tabs-empty-workspace.ts
|
||||
4 src/renderer/src/store/slices/tabs/tabs-focus-actions.ts
|
||||
@@ -91,11 +91,13 @@
|
||||
1 src/renderer/src/store/slices/tabs/tabs-hydration.ts
|
||||
8 src/renderer/src/store/slices/tabs/tabs-label-actions.ts
|
||||
10 src/renderer/src/store/slices/tabs/tabs-move-actions.ts
|
||||
9 src/renderer/src/store/slices/tabs/tabs-reconciliation.ts
|
||||
4 src/renderer/src/store/slices/tabs/tabs-reconciliation-batch.ts # split from tabs-reconciliation.ts (9 -> 2 + 4)
|
||||
2 src/renderer/src/store/slices/tabs/tabs-reconciliation.ts
|
||||
4 src/renderer/src/store/slices/tabs/tabs-session-actions.ts
|
||||
1 src/renderer/src/store/slices/tabs/tabs-split-ratio-actions.ts
|
||||
5 src/renderer/src/store/slices/tabs/tabs-surface.ts
|
||||
24 src/renderer/src/store/slices/tabs/worktree-layout-lifecycle.ts
|
||||
19 src/renderer/src/store/slices/tabs/worktree-layout-lifecycle.ts
|
||||
3 src/renderer/src/store/slices/tabs/worktree-terminal-tab-respawn.ts # moved unchanged out of worktree-layout-lifecycle.ts (24 -> 19 + 3)
|
||||
5 src/renderer/src/store/slices/worktrees/session/set-active-worktree.ts
|
||||
2 src/renderer/src/store/slices/worktrees/session/worktree-slice-lookups.ts
|
||||
6 src/renderer/src/store/terminals/create-terminal-slice.ts
|
||||
@@ -112,7 +114,7 @@
|
||||
10 src/renderer/src/store/terminals/terminal-tab-creation.ts
|
||||
7 src/renderer/src/store/terminals/terminal-tab-navigation.ts
|
||||
3 src/renderer/src/store/terminals/terminal-tab-presentation.ts
|
||||
4 src/renderer/src/store/terminals/terminal-tab-title-batch.ts
|
||||
2 src/renderer/src/store/terminals/terminal-tab-title-batch.ts
|
||||
5 src/renderer/src/store/terminals/workspace-terminal-hydration-patch.ts
|
||||
2 src/renderer/src/store/terminals/workspace-terminal-hydration.ts
|
||||
2 src/renderer/src/store/terminals/workspace-terminal-reconnect.ts
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { readFile } from 'node:fs/promises'
|
||||
import { readFile, readdir } from 'node:fs/promises'
|
||||
import { readRouteSnapshot } from '../../mobile-web-app/mobile-web-app-route-snapshot.mjs'
|
||||
import { MOBILE_WEB_APP_DEPENDENCY_PATH } from '../../mobile-web-app/mobile-web-app-bundle-dependencies.mjs'
|
||||
import { existsSync, realpathSync } from 'node:fs'
|
||||
@@ -24,6 +24,13 @@ import {
|
||||
routePathnameFromKey
|
||||
} from '../../mobile-web-app/mobile-web-app-route-manifest.mjs'
|
||||
import { MOBILE_WEB_PAGE_ROUTES } from './mobile-web-page-routes.mjs'
|
||||
import {
|
||||
ROUTE_ENTRY_NAMESPACE,
|
||||
entryStaticClosure,
|
||||
isScriptOutput,
|
||||
lazyModulesToAnchor,
|
||||
sharedModulesToMerge
|
||||
} from './mobile-web-app-chunk-grouping.mjs'
|
||||
|
||||
const projectDir = fileURLToPath(new URL('../../../..', import.meta.url))
|
||||
const mobileDir = join(projectDir, 'mobile')
|
||||
@@ -134,7 +141,7 @@ const HAIRLINE_PLUGIN_NAME = 'orca-hairline-device-pixel'
|
||||
const ENTRY_CHUNK_NAME = 'entry'
|
||||
|
||||
const ROUTE_MANIFEST_MODULE = /web-entry[\\/]route-manifest(\.ts)?$/
|
||||
const ROUTE_ENTRY_NAMESPACE = 'orca-route-entry'
|
||||
const LAZY_ENTRY_NAMESPACE = 'orca-lazy-entry'
|
||||
|
||||
// The entry's static imports as written, minus the manifest: a route importing it would be an output cycle.
|
||||
async function entryImportAnchors() {
|
||||
@@ -160,8 +167,14 @@ const escapeRegExp = (text) => text.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')
|
||||
// Keep typed route-manifest file for TS/Metro resolution; replace only its body for web.
|
||||
// Routes import the entry's imports first, so esbuild keeps those modules in one chunk instead of one per route subset.
|
||||
// Routes also import every module in sharedModules, which esbuild then puts in one chunk all routes load.
|
||||
function routeManifestPlugin(manifestSource, routes, sharedModules) {
|
||||
// Lazy modules in anchoredLazyModules (path to export names) get the same imports, so they don't split those chunks either.
|
||||
function routeManifestPlugin(manifestSource, routes, sharedModules, anchoredLazyModules) {
|
||||
let anchors
|
||||
const anchoredImports = async () => {
|
||||
anchors ??= entryImportAnchors()
|
||||
const shared = sharedModules.map((module) => `import ${JSON.stringify(module)}\n`).join('')
|
||||
return `${await anchors}${shared}`
|
||||
}
|
||||
return {
|
||||
name: ROUTE_MANIFEST_PLUGIN_NAME,
|
||||
setup(build) {
|
||||
@@ -170,26 +183,43 @@ function routeManifestPlugin(manifestSource, routes, sharedModules) {
|
||||
loader: 'js',
|
||||
resolveDir: mobileDir
|
||||
}))
|
||||
if (routes.length === 0) {
|
||||
return
|
||||
}
|
||||
const routeImport = new RegExp(
|
||||
`^(?:${routes.map(({ module }) => escapeRegExp(module)).join('|')})$`
|
||||
)
|
||||
build.onResolve({ filter: routeImport }, (args) =>
|
||||
args.kind === 'dynamic-import'
|
||||
? { path: args.path, namespace: ROUTE_ENTRY_NAMESPACE }
|
||||
: undefined
|
||||
)
|
||||
build.onLoad({ filter: /.*/, namespace: ROUTE_ENTRY_NAMESPACE }, async (args) => {
|
||||
anchors ??= entryImportAnchors()
|
||||
const shared = sharedModules.map((module) => `import ${JSON.stringify(module)}\n`).join('')
|
||||
return {
|
||||
contents: `${await anchors}${shared}export { default } from ${JSON.stringify(args.path)}\n`,
|
||||
if (routes.length > 0) {
|
||||
const routeImport = new RegExp(
|
||||
`^(?:${routes.map(({ module }) => escapeRegExp(module)).join('|')})$`
|
||||
)
|
||||
build.onResolve({ filter: routeImport }, (args) =>
|
||||
args.kind === 'dynamic-import'
|
||||
? { path: args.path, namespace: ROUTE_ENTRY_NAMESPACE }
|
||||
: undefined
|
||||
)
|
||||
build.onLoad({ filter: /.*/, namespace: ROUTE_ENTRY_NAMESPACE }, async (args) => ({
|
||||
contents: `${await anchoredImports()}export { default } from ${JSON.stringify(args.path)}\n`,
|
||||
loader: 'js',
|
||||
resolveDir: dirname(entryPoint)
|
||||
}))
|
||||
}
|
||||
if (anchoredLazyModules.size === 0) {
|
||||
return
|
||||
}
|
||||
build.onResolve({ filter: /.*/ }, async (args) => {
|
||||
if (args.kind !== 'dynamic-import' || args.pluginData === LAZY_ENTRY_NAMESPACE) {
|
||||
return undefined
|
||||
}
|
||||
const { path, errors } = await build.resolve(args.path, {
|
||||
kind: args.kind,
|
||||
importer: args.importer,
|
||||
resolveDir: args.resolveDir,
|
||||
pluginData: LAZY_ENTRY_NAMESPACE
|
||||
})
|
||||
return errors.length === 0 && anchoredLazyModules.has(path)
|
||||
? { path, namespace: LAZY_ENTRY_NAMESPACE }
|
||||
: undefined
|
||||
})
|
||||
build.onLoad({ filter: /.*/, namespace: LAZY_ENTRY_NAMESPACE }, async (args) => ({
|
||||
contents: `${await anchoredImports()}export { ${anchoredLazyModules.get(args.path).join(', ')} } from ${JSON.stringify(args.path)}\n`,
|
||||
loader: 'js',
|
||||
resolveDir: dirname(entryPoint)
|
||||
}))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -234,7 +264,11 @@ const hairlineDevicePixelPlugin = {
|
||||
}
|
||||
|
||||
/** Split out so a test can read the options MOBILE_WEB_APP_SHIMS claims, without a build. */
|
||||
export function mobileWebAppBuildOptions(routes, sharedModules = []) {
|
||||
export function mobileWebAppBuildOptions(
|
||||
routes,
|
||||
sharedModules = [],
|
||||
anchoredLazyModules = new Map()
|
||||
) {
|
||||
return {
|
||||
// Fixed so no absolute path of this checkout can reach the output.
|
||||
absWorkingDir: mobileDir,
|
||||
@@ -267,7 +301,12 @@ export function mobileWebAppBuildOptions(routes, sharedModules = []) {
|
||||
zod: MOBILE_ZOD_PACKAGE
|
||||
},
|
||||
plugins: [
|
||||
routeManifestPlugin(renderMobileWebAppRouteManifest(routes), routes, sharedModules),
|
||||
routeManifestPlugin(
|
||||
renderMobileWebAppRouteManifest(routes),
|
||||
routes,
|
||||
sharedModules,
|
||||
anchoredLazyModules
|
||||
),
|
||||
lucideBarrelPlugin,
|
||||
hairlineDevicePixelPlugin
|
||||
],
|
||||
@@ -311,66 +350,6 @@ export function mobileWebAppBuildOptions(routes, sharedModules = []) {
|
||||
}
|
||||
}
|
||||
|
||||
// Budget entry plus transitive static imports, stopping at dynamic imports; entry-only limits let shared initial chunks grow unseen.
|
||||
export function entryStaticClosure(metafile, entryOutputPath) {
|
||||
const reached = new Set([entryOutputPath])
|
||||
for (const current of reached) {
|
||||
for (const imported of metafile.outputs[current]?.imports ?? []) {
|
||||
if (imported.kind !== 'import-statement' || reached.has(imported.path)) {
|
||||
continue
|
||||
}
|
||||
reached.add(imported.path)
|
||||
}
|
||||
}
|
||||
return reached
|
||||
}
|
||||
|
||||
// esbuild cuts a chunk per set of routes sharing a module; one this small costs more as a request than as code every route loads.
|
||||
const MERGED_SHARED_CHUNK_MAX_BYTES = 16 * 1024
|
||||
|
||||
// Small route-shared chunks whose static imports already load at boot or merge too, so merging adds only their own bytes.
|
||||
// ESM only: a bare import runs a CommonJS module's body at route load, not where its importer first needs it.
|
||||
function sharedModulesToMerge(metafile, entryOutputPath) {
|
||||
const { inputs, outputs } = metafile
|
||||
const boot = entryStaticClosure(metafile, entryOutputPath)
|
||||
const routeReached = new Set(
|
||||
Object.entries(outputs)
|
||||
.filter(([, output]) => output.entryPoint?.startsWith(`${ROUTE_ENTRY_NAMESPACE}:`))
|
||||
.flatMap(([path]) => [...entryStaticClosure(metafile, path)])
|
||||
)
|
||||
const merged = new Set(
|
||||
Object.entries(outputs)
|
||||
.filter(
|
||||
([path, output]) =>
|
||||
isScriptOutput(path) &&
|
||||
!output.entryPoint &&
|
||||
!boot.has(path) &&
|
||||
routeReached.has(path) &&
|
||||
output.bytes <= MERGED_SHARED_CHUNK_MAX_BYTES &&
|
||||
Object.keys(output.inputs).every((input) => inputs[input]?.format === 'esm')
|
||||
)
|
||||
.map(([path]) => path)
|
||||
)
|
||||
const importsUnmerged = (path) =>
|
||||
outputs[path].imports.some(
|
||||
({ kind, path: imported }) =>
|
||||
kind === 'import-statement' && !boot.has(imported) && !merged.has(imported)
|
||||
)
|
||||
for (let dropped = true; dropped;) {
|
||||
dropped = false
|
||||
for (const path of merged) {
|
||||
if (importsUnmerged(path)) {
|
||||
merged.delete(path)
|
||||
dropped = true
|
||||
}
|
||||
}
|
||||
}
|
||||
return [...merged]
|
||||
.flatMap((path) => Object.keys(outputs[path].inputs))
|
||||
.sort()
|
||||
.map((input) => resolve(mobileDir, input))
|
||||
}
|
||||
|
||||
// Hash final output bytes leaf-first, rewriting dependency names before hashing importers.
|
||||
// esbuild hashes checkout-dependent input paths; renaming makes manifest hashes/import URLs agree and avoids redownloading identical bundles across checkouts.
|
||||
export function renameOutputsByContent(metafile, outputFiles) {
|
||||
@@ -438,8 +417,6 @@ export function routeChunkNames(metafile, routes, renamed) {
|
||||
)
|
||||
}
|
||||
|
||||
const isScriptOutput = (path) => path.endsWith('.js')
|
||||
|
||||
// appDir is a seam for the tests, which bundle a scratch route tree; production always uses mobile/app.
|
||||
// Page closure includes ancestor layouts as entry modules, not just route imports.
|
||||
export async function mobileWebAppRouteClosure(routeModule) {
|
||||
@@ -480,6 +457,32 @@ export async function mobileWebAppModuleClosure(entryModules, { absWorkingDir }
|
||||
|
||||
// One lazily imported chunk per UI language; the page fetches only the active one after init.
|
||||
const LOCALE_CATALOG_INPUT = /(^|\/)src\/i18n\/locales\/[^/]+\.json$/
|
||||
const localeCatalogDir = join(mobileDir, 'src', 'i18n', 'locales')
|
||||
|
||||
// The same catalogs as JSON for the host to serve one at a time, to shells that skip the chunks;
|
||||
// English is the page's inline fallback, so it has none.
|
||||
export async function readLocaleCatalogs(directory = localeCatalogDir) {
|
||||
const names = (await readdir(directory))
|
||||
.filter((name) => name.endsWith('.json') && name !== 'en.json')
|
||||
.sort()
|
||||
return Promise.all(
|
||||
names.map(async (name) => {
|
||||
// Minify: the host sends and the phone keeps the parsed object, not the source layout.
|
||||
const bytes = Buffer.from(
|
||||
JSON.stringify(JSON.parse(await readFile(join(directory, name), 'utf8'))),
|
||||
'utf8'
|
||||
)
|
||||
const sha256 = sha256Hex(bytes)
|
||||
return {
|
||||
locale: name.slice(0, -'.json'.length),
|
||||
bytes,
|
||||
path: `catalogs/${sha256}.json`,
|
||||
sha256,
|
||||
byteLength: bytes.byteLength
|
||||
}
|
||||
})
|
||||
)
|
||||
}
|
||||
|
||||
function localeCatalogOutputs(metafile) {
|
||||
return new Set(
|
||||
@@ -532,10 +535,12 @@ function entryOutput(metafile) {
|
||||
// The page's scripts as shipped: a first build finds the small shared chunks, a second merges them.
|
||||
export async function buildMobileWebAppScripts(routes) {
|
||||
const split = await esbuild.build(mobileWebAppBuildOptions(routes))
|
||||
const sharedModules = sharedModulesToMerge(split.metafile, entryOutput(split.metafile))
|
||||
return sharedModules.length === 0
|
||||
const entryOutputPath = entryOutput(split.metafile)
|
||||
const sharedModules = sharedModulesToMerge(split.metafile, entryOutputPath)
|
||||
const anchoredLazyModules = lazyModulesToAnchor(split.metafile, entryOutputPath)
|
||||
return sharedModules.length === 0 && anchoredLazyModules.size === 0
|
||||
? split
|
||||
: esbuild.build(mobileWebAppBuildOptions(routes, sharedModules))
|
||||
: esbuild.build(mobileWebAppBuildOptions(routes, sharedModules, anchoredLazyModules))
|
||||
}
|
||||
|
||||
export async function bundleMobileWebApp({ appDir = defaultAppDir } = {}) {
|
||||
@@ -599,17 +604,21 @@ export function resolveMobileWebPageRoutes(routeKeys, declared = MOBILE_WEB_PAGE
|
||||
export async function buildMobileWebAppBundle({
|
||||
appDir,
|
||||
outDir = defaultOutDir,
|
||||
pageRoutes = MOBILE_WEB_PAGE_ROUTES
|
||||
pageRoutes = MOBILE_WEB_PAGE_ROUTES,
|
||||
// Only the shipped tree pays for brotli-11; tests and verify's scratch builds read raw assets.
|
||||
brotli = false
|
||||
} = {}) {
|
||||
const [
|
||||
desktopVersion,
|
||||
protocolWindow,
|
||||
{ script, chunks, images, catalogChunks, entryStaticBytes, chunkCount, routeChunks, routeKeys },
|
||||
catalogs,
|
||||
scrollbarStyle
|
||||
] = await Promise.all([
|
||||
readDesktopVersion(),
|
||||
readProtocolWindow(),
|
||||
bundleMobileWebApp({ appDir }),
|
||||
readLocaleCatalogs(),
|
||||
readFile(join(projectDir, 'src/shared/styles/scrollbar-sleek.css'), 'utf8').then((style) =>
|
||||
// The shared desktop stylesheet can be checked out as CRLF on Windows.
|
||||
style.replace(/\r\n/g, '\n')
|
||||
@@ -617,9 +626,14 @@ export async function buildMobileWebAppBundle({
|
||||
])
|
||||
// Names already hash final bytes, so hashedAsset must reproduce them.
|
||||
const scriptAsset = hashedAsset(script, 'js')
|
||||
const catalogChunkSet = new Set(catalogChunks)
|
||||
const written = [
|
||||
scriptAsset,
|
||||
...[...chunks, ...images].map(({ name, bytes }) => hashedAsset(bytes, extname(name).slice(1)))
|
||||
...[...chunks, ...images].map((output) => ({
|
||||
...hashedAsset(output.bytes, extname(output.name).slice(1)),
|
||||
// Shells that read catalogs from the host skip these; older shells download them as before.
|
||||
...(catalogChunkSet.has(output) ? { kind: 'catalog' } : {})
|
||||
}))
|
||||
]
|
||||
|
||||
// Root-absolute URLs survive nested routes; CSP allows only about: base. ESM entry/chunks load under existing self policy.
|
||||
@@ -643,9 +657,11 @@ export async function buildMobileWebAppBundle({
|
||||
const { manifest } = await writeMobileWebBundleTree({
|
||||
outDir,
|
||||
written: [indexAsset, ...written],
|
||||
catalogs,
|
||||
desktopVersion,
|
||||
protocolWindow,
|
||||
routes: resolveMobileWebPageRoutes(routeKeys, pageRoutes)
|
||||
routes: resolveMobileWebPageRoutes(routeKeys, pageRoutes),
|
||||
brotli
|
||||
})
|
||||
return {
|
||||
manifest,
|
||||
@@ -670,7 +686,7 @@ if (isDirectInvocation(import.meta.url, process.argv[1])) {
|
||||
}
|
||||
try {
|
||||
const { manifest, outDir, routeKeys, entryStaticBytes, chunkCount } =
|
||||
await buildMobileWebAppBundle()
|
||||
await buildMobileWebAppBundle({ brotli: true })
|
||||
console.log(
|
||||
`[build-mobile-web-app-bundle] OK — ${String(routeKeys.length)} route(s), ` +
|
||||
`${String(chunkCount)} chunk(s), ${String(entryStaticBytes)} bytes before the first route, ` +
|
||||
|
||||
@@ -0,0 +1,102 @@
|
||||
import { realpathSync } from 'node:fs'
|
||||
import { resolve } from 'node:path'
|
||||
import { fileURLToPath } from 'node:url'
|
||||
|
||||
const mobileDir = fileURLToPath(new URL('../../../../mobile', import.meta.url))
|
||||
|
||||
export const ROUTE_ENTRY_NAMESPACE = 'orca-route-entry'
|
||||
|
||||
export const isScriptOutput = (path) => path.endsWith('.js')
|
||||
|
||||
// Budget entry plus transitive static imports, stopping at dynamic imports; entry-only limits let shared initial chunks grow unseen.
|
||||
export function entryStaticClosure(metafile, entryOutputPath) {
|
||||
const reached = new Set([entryOutputPath])
|
||||
for (const current of reached) {
|
||||
for (const imported of metafile.outputs[current]?.imports ?? []) {
|
||||
if (imported.kind !== 'import-statement' || reached.has(imported.path)) {
|
||||
continue
|
||||
}
|
||||
reached.add(imported.path)
|
||||
}
|
||||
}
|
||||
return reached
|
||||
}
|
||||
|
||||
// esbuild cuts a chunk per set of routes sharing a module; one this small costs more as a request than as code every route loads.
|
||||
const MERGED_SHARED_CHUNK_MAX_BYTES = 16 * 1024
|
||||
|
||||
// Small route-shared chunks whose static imports already load at boot or merge too, so merging adds only their own bytes.
|
||||
// ESM only: a bare import runs a CommonJS module's body at route load, not where its importer first needs it.
|
||||
export function sharedModulesToMerge(metafile, entryOutputPath) {
|
||||
const { inputs, outputs } = metafile
|
||||
const boot = entryStaticClosure(metafile, entryOutputPath)
|
||||
const routeReached = new Set(
|
||||
Object.entries(outputs)
|
||||
.filter(([, output]) => output.entryPoint?.startsWith(`${ROUTE_ENTRY_NAMESPACE}:`))
|
||||
.flatMap(([path]) => [...entryStaticClosure(metafile, path)])
|
||||
)
|
||||
const merged = new Set(
|
||||
Object.entries(outputs)
|
||||
.filter(
|
||||
([path, output]) =>
|
||||
isScriptOutput(path) &&
|
||||
!output.entryPoint &&
|
||||
!boot.has(path) &&
|
||||
routeReached.has(path) &&
|
||||
output.bytes <= MERGED_SHARED_CHUNK_MAX_BYTES &&
|
||||
Object.keys(output.inputs).every((input) => inputs[input]?.format === 'esm')
|
||||
)
|
||||
.map(([path]) => path)
|
||||
)
|
||||
const importsUnmerged = (path) =>
|
||||
outputs[path].imports.some(
|
||||
({ kind, path: imported }) =>
|
||||
kind === 'import-statement' && !boot.has(imported) && !merged.has(imported)
|
||||
)
|
||||
for (let dropped = true; dropped;) {
|
||||
dropped = false
|
||||
for (const path of merged) {
|
||||
if (importsUnmerged(path)) {
|
||||
merged.delete(path)
|
||||
dropped = true
|
||||
}
|
||||
}
|
||||
}
|
||||
return [...merged]
|
||||
.flatMap((path) => Object.keys(outputs[path].inputs))
|
||||
.sort()
|
||||
.map((input) => resolve(mobileDir, input))
|
||||
}
|
||||
|
||||
// A lazy module sharing boot code gives those modules a new importer set, so esbuild would split the boot chunks;
|
||||
// anchor it like a route. Modules boot imports lazily (routes, catalogs) stay as they are: anchoring them is an output cycle.
|
||||
// esbuild's runtime helper chunk has no inputs and every chunk imports it, so self-contained engines (mermaid) keep their bytes.
|
||||
export function lazyModulesToAnchor(metafile, entryOutputPath) {
|
||||
const { outputs } = metafile
|
||||
const boot = entryStaticClosure(metafile, entryOutputPath)
|
||||
const bootLoadsLazily = new Set(
|
||||
[...boot].flatMap((path) =>
|
||||
outputs[path].imports
|
||||
.filter(({ kind }) => kind === 'dynamic-import')
|
||||
.map(({ path: imported }) => imported)
|
||||
)
|
||||
)
|
||||
const sharesBootModules = ({ imports }) =>
|
||||
imports.some(
|
||||
({ kind, path }) =>
|
||||
kind === 'import-statement' &&
|
||||
boot.has(path) &&
|
||||
Object.keys(outputs[path].inputs).length > 0
|
||||
)
|
||||
return new Map(
|
||||
Object.entries(outputs)
|
||||
.filter(
|
||||
([path, output]) =>
|
||||
output.entryPoint &&
|
||||
!boot.has(path) &&
|
||||
!bootLoadsLazily.has(path) &&
|
||||
sharesBootModules(output)
|
||||
)
|
||||
.map(([, output]) => [realpathSync(resolve(mobileDir, output.entryPoint)), output.exports])
|
||||
)
|
||||
}
|
||||
@@ -15,7 +15,11 @@ const PIXEL_PNG = Buffer.from(
|
||||
'base64'
|
||||
)
|
||||
|
||||
export async function writeMobileWebBundleFixtureTree({ outDir, body = 'fixture' }) {
|
||||
export async function writeMobileWebBundleFixtureTree({
|
||||
outDir,
|
||||
body = 'fixture',
|
||||
brotli = false
|
||||
}) {
|
||||
const [desktopVersion, protocolWindow] = await Promise.all([
|
||||
readDesktopVersion(),
|
||||
readProtocolWindow()
|
||||
@@ -49,6 +53,7 @@ export async function writeMobileWebBundleFixtureTree({ outDir, body = 'fixture'
|
||||
image
|
||||
],
|
||||
desktopVersion,
|
||||
protocolWindow
|
||||
protocolWindow,
|
||||
brotli
|
||||
})
|
||||
}
|
||||
|
||||
@@ -3,10 +3,13 @@ import { readFile, mkdir, rm, writeFile } from 'node:fs/promises'
|
||||
import { createRequire } from 'node:module'
|
||||
import { join } from 'node:path'
|
||||
import { fileURLToPath } from 'node:url'
|
||||
import { promisify } from 'node:util'
|
||||
import { brotliCompress, constants as zlibConstants } from 'node:zlib'
|
||||
|
||||
const { darkBuildMarkers } = createRequire(import.meta.url)('../../../dark-build-switches.cjs')
|
||||
|
||||
const projectDir = fileURLToPath(new URL('../../../..', import.meta.url))
|
||||
const brotliCompressAsync = promisify(brotliCompress)
|
||||
|
||||
export const MOBILE_WEB_BUNDLE_SCHEMA_VERSION = 1
|
||||
export const MOBILE_WEB_BUNDLE_ENTRYPOINT = 'index.html'
|
||||
@@ -101,18 +104,58 @@ export async function readDesktopVersion() {
|
||||
return packageJson.version
|
||||
}
|
||||
|
||||
// Mirrors mobileWebBundleBrotliPath in src/shared/mobile-web-bundle/manifest-contract.ts.
|
||||
export function mobileWebBundleBrotliPath(assetPath) {
|
||||
return `${assetPath}.br`
|
||||
}
|
||||
|
||||
// Largest first so the slowest file starts first on zlib's thread pool; keep only copies that shrink.
|
||||
async function compressWithBrotli(written) {
|
||||
const largestFirst = [...written].sort((left, right) => right.byteLength - left.byteLength)
|
||||
const copies = await Promise.all(
|
||||
largestFirst.map((asset) =>
|
||||
brotliCompressAsync(asset.bytes, {
|
||||
params: {
|
||||
[zlibConstants.BROTLI_PARAM_QUALITY]: zlibConstants.BROTLI_MAX_QUALITY,
|
||||
[zlibConstants.BROTLI_PARAM_SIZE_HINT]: asset.byteLength
|
||||
}
|
||||
})
|
||||
)
|
||||
)
|
||||
return new Map(
|
||||
largestFirst.flatMap((asset, index) =>
|
||||
copies[index].byteLength < asset.byteLength ? [[asset.path, copies[index]]] : []
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
// Single manifest producer keeps builder/contract/packaging guard shape aligned.
|
||||
export async function writeMobileWebBundleTree({
|
||||
outDir,
|
||||
written,
|
||||
// Host-only JSON outside `assets` and buildId, served one at a time over RPC.
|
||||
catalogs = [],
|
||||
desktopVersion,
|
||||
protocolWindow,
|
||||
// Empty route list makes shell render every screen natively.
|
||||
routes = [],
|
||||
// Whole-file brotli copies for phones that inflate natively.
|
||||
brotli = false,
|
||||
env = process.env
|
||||
}) {
|
||||
const brotliCopies = brotli ? await compressWithBrotli(written) : new Map()
|
||||
const assets = written
|
||||
.map(({ path, sha256, byteLength, contentType }) => ({ path, sha256, byteLength, contentType }))
|
||||
.map(({ path, sha256, byteLength, contentType, kind }) => {
|
||||
const copy = brotliCopies.get(path)
|
||||
return {
|
||||
path,
|
||||
sha256,
|
||||
byteLength,
|
||||
contentType,
|
||||
...(copy === undefined ? {} : { brotliByteLength: copy.byteLength }),
|
||||
...(kind === undefined ? {} : { kind })
|
||||
}
|
||||
})
|
||||
.sort((left, right) => (left.path < right.path ? -1 : left.path > right.path ? 1 : 0))
|
||||
const manifest = {
|
||||
schemaVersion: MOBILE_WEB_BUNDLE_SCHEMA_VERSION,
|
||||
@@ -124,14 +167,30 @@ export async function writeMobileWebBundleTree({
|
||||
entrypoint: MOBILE_WEB_BUNDLE_ENTRYPOINT,
|
||||
totalBytes: assets.reduce((total, asset) => total + asset.byteLength, 0),
|
||||
assets,
|
||||
routes
|
||||
routes,
|
||||
...(catalogs.length === 0
|
||||
? {}
|
||||
: {
|
||||
catalogs: catalogs.map(({ locale, path, sha256, byteLength }) => ({
|
||||
locale,
|
||||
path,
|
||||
sha256,
|
||||
byteLength
|
||||
}))
|
||||
})
|
||||
}
|
||||
|
||||
// Clear entire output or stale unreferenced assets ship inside asar.
|
||||
await rm(outDir, { recursive: true, force: true })
|
||||
await mkdir(join(outDir, 'assets'), { recursive: true })
|
||||
for (const asset of written) {
|
||||
await writeFile(join(outDir, asset.path), asset.bytes)
|
||||
if (catalogs.length > 0) {
|
||||
await mkdir(join(outDir, 'catalogs'), { recursive: true })
|
||||
}
|
||||
for (const file of [...written, ...catalogs]) {
|
||||
await writeFile(join(outDir, file.path), file.bytes)
|
||||
}
|
||||
for (const [path, copy] of brotliCopies) {
|
||||
await writeFile(join(outDir, mobileWebBundleBrotliPath(path)), copy)
|
||||
}
|
||||
await writeFile(join(outDir, 'manifest.json'), `${JSON.stringify(manifest, null, 2)}\n`, 'utf8')
|
||||
// Keep switch metadata outside manifest so compiled page bytes/buildId remain unchanged.
|
||||
|
||||
@@ -102,13 +102,14 @@ export const MOBILE_WEB_PAGE_ROUTES = [
|
||||
'native.audio.read',
|
||||
'native.audio.stop'
|
||||
],
|
||||
// Optional media.name falls back to the file type; terminalKeyRail falls back to the page's row; the image viewer drops its actions without native.image.act; dictation uses the computer without native.speech.act.
|
||||
// Optional media.name falls back to the file type; terminalKeyRail falls back to the page's row; the image viewer drops its actions without native.image.act; dictation uses the computer without native.speech.act; without native.a11y.announce only the page's live region speaks.
|
||||
optionalGrants: [
|
||||
'externalNavigation',
|
||||
'native.media.name',
|
||||
'native.pdf.view',
|
||||
'native.image.act',
|
||||
'native.speech.act',
|
||||
'native.a11y.announce',
|
||||
'terminalKeyRail',
|
||||
DEVICE_STORE_GRANT
|
||||
]
|
||||
|
||||
@@ -29,6 +29,8 @@ export function mobileWebAppBundleMaxAssets(routeCount, imageCount, catalogChunk
|
||||
// fetched only for the active language, never before the first route. Code keeps its own fence.
|
||||
export const MOBILE_WEB_APP_BUNDLE_MAX_CATALOG_CHUNKS = 10
|
||||
export const MOBILE_WEB_APP_BUNDLE_MAX_CATALOG_BYTES = 3 * 1024 * 1024
|
||||
// The host sends a catalog's JSON in one reply, which must fit a 1 MiB relay frame once encrypted.
|
||||
export const MOBILE_WEB_APP_HOST_CATALOG_MAX_BYTES = 384 * 1024
|
||||
|
||||
// Our own fence on the page's code, well inside the phone contract (32 MiB total, 10 MiB per asset in
|
||||
// manifest-contract.ts); it fails the build before the code weighs more than any one asset may.
|
||||
@@ -185,6 +187,23 @@ export async function verifyMobileWebAppBundle({ bundleDir = defaultBundleDir }
|
||||
`${String(MOBILE_WEB_APP_BUNDLE_MAX_CATALOG_BYTES)} bytes`
|
||||
)
|
||||
}
|
||||
// buildId leaves the host's JSON catalogs out, so a stale copy shows only here.
|
||||
const hostCatalogsOf = (built) => JSON.stringify(built.catalogs ?? [])
|
||||
if (hostCatalogsOf(first.manifest) !== hostCatalogsOf(second.manifest)) {
|
||||
fail('host language catalogs are not reproducible')
|
||||
}
|
||||
if (hostCatalogsOf(first.manifest) !== hostCatalogsOf(manifest)) {
|
||||
fail(`${bundleDir} is stale: its host language catalogs differ from a fresh build's`)
|
||||
}
|
||||
const oversized = (manifest.catalogs ?? []).find(
|
||||
(catalog) => catalog.byteLength > MOBILE_WEB_APP_HOST_CATALOG_MAX_BYTES
|
||||
)
|
||||
if (oversized) {
|
||||
fail(
|
||||
`the ${oversized.locale} host catalog is ${String(oversized.byteLength)} bytes, over the ` +
|
||||
`${String(MOBILE_WEB_APP_HOST_CATALOG_MAX_BYTES)} one reply carries`
|
||||
)
|
||||
}
|
||||
const budgetBytes = mobileWebAppBundleBudgetBytes(manifest) - first.catalogBytes
|
||||
if (budgetBytes > MOBILE_WEB_APP_BUNDLE_MAX_TOTAL_BYTES) {
|
||||
fail(
|
||||
|
||||
@@ -4589,7 +4589,6 @@
|
||||
"src/packages/process-host/src/run-process-windows-tree-kill.test.ts": 81,
|
||||
"src/packages/process-host/src/run-process.test.ts": 9406,
|
||||
"src/packages/process-host/src/spawn-observer.test.ts": 357,
|
||||
"src/packages/process-host/src/spawn-process-stdio.test.ts": 311,
|
||||
"src/packages/process-host/src/windows-command-line.test.ts": 73,
|
||||
"src/packages/process-host/src/windows-tree-kill.test.ts": 81,
|
||||
"src/packages/process-host/src/wsl-distro-allowlist.test.ts": 55,
|
||||
@@ -4623,11 +4622,9 @@
|
||||
"src/preload/usage-provider-api.test.ts": 46,
|
||||
"src/renderer/src/app-shell/app-command-handlers-tab-rename.test.ts": 1786,
|
||||
"src/renderer/src/app-shell/shutdown-checkpoint-persist.test.ts": 65,
|
||||
"src/renderer/src/app-shell/shutdown-checkpoint-restart-lifecycle.test.ts": 210,
|
||||
"src/renderer/src/app-shell/startup-window-parity.test.ts": 2306,
|
||||
"src/renderer/src/app-shell/use-profile-state-save-delay-notice.sonner.test.tsx": 355,
|
||||
"src/renderer/src/app-shell/use-profile-state-save-delay-notice.test.tsx": 293,
|
||||
"src/renderer/src/app-shell/use-visible-hosted-review-refresh.test.tsx": 572,
|
||||
"src/renderer/src/app-shell/visible-review-reporting.test.ts": 1872,
|
||||
"src/renderer/src/app-shell/workspace-view-cross-client-sync.test.tsx": 1170,
|
||||
"src/renderer/src/app-shell/worktree-creation-chat-handoff.test.tsx": 2824,
|
||||
@@ -4642,12 +4639,8 @@
|
||||
"src/renderer/src/components/JiraIssueWorkspace.optimistic-edit.test.tsx": 2340,
|
||||
"src/renderer/src/components/JiraIssueWorkspace.status-queue.test.tsx": 1852,
|
||||
"src/renderer/src/components/JiraIssueWorkspace.transition-source.test.tsx": 1843,
|
||||
"src/renderer/src/components/NativeChatRemoteResume.test.tsx": 8774,
|
||||
"src/renderer/src/components/NativeChatResumeOnRestartGroups.selection.test.tsx": 2633,
|
||||
"src/renderer/src/components/NativeChatResumeOnRestartGroups.test.tsx": 3472,
|
||||
"src/renderer/src/components/NewWorkspaceComposerCard.quick-file-drop.test.tsx": 4557,
|
||||
"src/renderer/src/components/NewWorkspaceComposerCard.set-location.test.tsx": 1301,
|
||||
"src/renderer/src/components/QuickOpen.selection.test.tsx": 1046,
|
||||
"src/renderer/src/components/SelectedTextCopyMenu.test.tsx": 329,
|
||||
"src/renderer/src/components/TerminalSearch.test.tsx": 458,
|
||||
"src/renderer/src/components/UpdateCard.error-card.test.tsx": 2851,
|
||||
@@ -4676,56 +4669,46 @@
|
||||
"src/renderer/src/components/artifacts/ArtifactPublishButton.test.tsx": 706,
|
||||
"src/renderer/src/components/artifacts/ArtifactsPage.test.tsx": 2052,
|
||||
"src/renderer/src/components/artifacts/artifact-publish-flow.test.ts": 114,
|
||||
"src/renderer/src/components/automations/AutomationEditorPromptEditor.test.tsx": 396,
|
||||
"src/renderer/src/components/automations/authoring/AutomationEditorPromptEditor.test.tsx": 396,
|
||||
"src/renderer/src/components/automations/AutomationPromptDisclosure.test.tsx": 893,
|
||||
"src/renderer/src/components/automations/AutomationRunsTable.test.tsx": 668,
|
||||
"src/renderer/src/components/automations/AutomationSchedulePicker.test.ts": 431,
|
||||
"src/renderer/src/components/automations/AutomationTimeField.test.tsx": 654,
|
||||
"src/renderer/src/components/automations/authoring/AutomationSchedulePicker.test.ts": 431,
|
||||
|
||||
"src/renderer/src/components/automations/AutomationsPage.behavior.test.tsx": 3389,
|
||||
"src/renderer/src/components/automations/AutomationsPage.edit-destination.test.tsx": 2932,
|
||||
"src/renderer/src/components/automations/AutomationsPage.run-navigation.test.tsx": 3056,
|
||||
|
||||
"src/renderer/src/components/automations/ExternalAutomationManagers.test.tsx": 852,
|
||||
"src/renderer/src/components/automations/automation-captured-owner.test.ts": 379,
|
||||
"src/renderer/src/components/automations/automation-create-projects.test.ts": 42,
|
||||
"src/renderer/src/components/automations/hosts/automation-captured-owner.test.ts": 379,
|
||||
"src/renderer/src/components/automations/automation-host-cache-controller.test.ts": 411,
|
||||
"src/renderer/src/components/automations/automation-host-cache-error.test.ts": 391,
|
||||
"src/renderer/src/components/automations/automation-host-cache-health.test.ts": 52,
|
||||
"src/renderer/src/components/automations/automation-host-cache.test.ts": 79,
|
||||
"src/renderer/src/components/automations/automation-host-catalog-generation.test.ts": 258,
|
||||
"src/renderer/src/components/automations/automation-host-client.test.ts": 374,
|
||||
"src/renderer/src/components/automations/hosts/automation-host-cache.test.ts": 79,
|
||||
|
||||
"src/renderer/src/components/automations/automation-host-diagnostics.test.ts": 460,
|
||||
"src/renderer/src/components/automations/automation-host-filter-resolution.test.ts": 256,
|
||||
"src/renderer/src/components/automations/automation-host-health.test.ts": 47,
|
||||
|
||||
"src/renderer/src/components/automations/automation-host-invalidation-window-events.test.ts": 83,
|
||||
"src/renderer/src/components/automations/automation-host-invalidation.test.ts": 85,
|
||||
"src/renderer/src/components/automations/automation-host-list-rows.test.ts": 419,
|
||||
"src/renderer/src/components/automations/automation-host-recovery.test.ts": 51,
|
||||
"src/renderer/src/components/automations/hosts/automation-host-list-rows.test.ts": 419,
|
||||
"src/renderer/src/components/automations/automation-host-scale-gates.test.ts": 638,
|
||||
"src/renderer/src/components/automations/automation-host-scheduler.test.ts": 439,
|
||||
"src/renderer/src/components/automations/automation-legacy-schedule-editing.test.ts": 449,
|
||||
"src/renderer/src/components/automations/automation-list-focus-recovery.test.ts": 48,
|
||||
"src/renderer/src/components/automations/automation-list-row-identity.test.ts": 626,
|
||||
"src/renderer/src/components/automations/automation-list-search.test.ts": 75,
|
||||
"src/renderer/src/components/automations/hosts/automation-host-scheduler.test.ts": 439,
|
||||
"src/renderer/src/components/automations/authoring/automation-legacy-schedule-editing.test.ts": 449,
|
||||
|
||||
"src/renderer/src/components/automations/automation-list-view.test.ts": 257,
|
||||
"src/renderer/src/components/automations/automation-run-context.test.ts": 58,
|
||||
"src/renderer/src/components/automations/automation-run-history-keyboard-navigation.test.ts": 434,
|
||||
"src/renderer/src/components/automations/automation-run-open-target.test.ts": 442,
|
||||
"src/renderer/src/components/automations/runs/automation-run-history-keyboard-navigation.test.ts": 434,
|
||||
"src/renderer/src/components/automations/runs/automation-run-open-target.test.ts": 442,
|
||||
"src/renderer/src/components/automations/automation-run-output-snapshot-equivalence.test.ts": 158,
|
||||
"src/renderer/src/components/automations/automation-run-output-snapshot.test.ts": 96,
|
||||
"src/renderer/src/components/automations/automation-setup-decision.test.ts": 58,
|
||||
"src/renderer/src/components/automations/authoring/automation-setup-decision.test.ts": 58,
|
||||
"src/renderer/src/components/automations/automation-usage-model.test.ts": 200,
|
||||
"src/renderer/src/components/automations/external-automation-list-entries.test.ts": 57,
|
||||
"src/renderer/src/components/automations/external-automation-scope-gating.test.ts": 67,
|
||||
"src/renderer/src/components/automations/external/external-automation-scope-gating.test.ts": 67,
|
||||
"src/renderer/src/components/automations/external-automation-scope-keys.test.ts": 53,
|
||||
"src/renderer/src/components/automations/use-automation-host-catalog-readoption.test.tsx": 802,
|
||||
"src/renderer/src/components/automations/use-automation-host-catalog.test.tsx": 920,
|
||||
"src/renderer/src/components/automations/use-automation-list-focus-recovery.test.tsx": 229,
|
||||
"src/renderer/src/components/automations/use-automation-list-search.test.tsx": 679,
|
||||
"src/renderer/src/components/automations/use-automation-runs-dashboard-payload.test.tsx": 6692,
|
||||
"src/renderer/src/components/automations/use-automation-runs-dashboard.test.tsx": 854,
|
||||
"src/renderer/src/components/automations/hosts/use-automation-host-catalog-readoption.test.tsx": 802,
|
||||
"src/renderer/src/components/automations/hosts/use-automation-host-catalog.test.tsx": 920,
|
||||
|
||||
"src/renderer/src/components/automations/listing/use-automation-list-search.test.tsx": 679,
|
||||
"src/renderer/src/components/automations/runs/use-automation-runs-dashboard-payload.test.tsx": 6692,
|
||||
"src/renderer/src/components/automations/runs/use-automation-runs-dashboard.test.tsx": 854,
|
||||
"src/renderer/src/components/automations/use-selected-automation-run-history.test.tsx": 2104,
|
||||
"src/renderer/src/components/browser-favicon.test.tsx": 333,
|
||||
"src/renderer/src/components/browser-pane/ClientHostedBrowserPagePane.dead-guest.test.tsx": 6219,
|
||||
"src/renderer/src/components/browser-pane/ClientHostedBrowserPagePane.drag-focus.test.tsx": 5826,
|
||||
"src/renderer/src/components/browser-pane/ClientHostedBrowserPagePane.failure-remount.test.tsx": 3085,
|
||||
"src/renderer/src/components/browser-pane/ClientHostedBrowserPagePane.markup.test.tsx": 4575,
|
||||
@@ -4822,7 +4805,6 @@
|
||||
"src/renderer/src/components/dashboard-popout/preview-terminal-box-fit-lifecycle.test.ts": 192,
|
||||
"src/renderer/src/components/dashboard-popout/preview-terminal-ime-bridge-kitty-bytes.test.ts": 479,
|
||||
"src/renderer/src/components/dashboard-popout/remote-runtime-terminal-preview-api.test.ts": 81,
|
||||
"src/renderer/src/components/dashboard-popout/use-agent-dashboard-telemetry.test.ts": 2108,
|
||||
"src/renderer/src/components/dashboard-popout/useDashboardSnapshot.test.tsx": 432,
|
||||
"src/renderer/src/components/dashboard/AgentDashboardDrawer.focus.test.tsx": 2567,
|
||||
"src/renderer/src/components/dashboard/AgentDashboardDrawer.test.tsx": 1981,
|
||||
@@ -4844,14 +4826,11 @@
|
||||
"src/renderer/src/components/diff-comments/diff-comment-popover-outside-click.test.tsx": 1889,
|
||||
"src/renderer/src/components/diff-comments/useDiffCommentDecorator.lifecycle.test.tsx": 2669,
|
||||
"src/renderer/src/components/diff-comments/useDiffCommentDecorator.range-selection.test.tsx": 1782,
|
||||
"src/renderer/src/components/editor/check-details/panel/CheckRunDetailsPanel.captured-failure.test.tsx": 2412,
|
||||
"src/renderer/src/components/editor/check-details/panel/CheckRunDetailsPanel.copy.test.tsx": 3108,
|
||||
"src/renderer/src/components/editor/check-details/panel/CheckRunDetailsPanel.log-outcomes.test.tsx": 3230,
|
||||
"src/renderer/src/components/editor/DiagramViewerModal.test.tsx": 2539,
|
||||
"src/renderer/src/components/editor/diff/sections/DiffSectionBody.word-wrap-lifecycle.test.tsx": 3036,
|
||||
"src/renderer/src/components/editor/diff/monaco-view/DiffViewer.word-wrap-lifecycle.test.tsx": 2499,
|
||||
"src/renderer/src/components/editor/EditorConflictReviewSurface.live-record.test.tsx": 1193,
|
||||
"src/renderer/src/components/editor/EditorContent.monaco-lifecycle.test.tsx": 3162,
|
||||
"src/renderer/src/components/editor/EditorEditFileSurface.monaco-containment.test.tsx": 2666,
|
||||
"src/renderer/src/components/editor/EditorFileLoadErrorView.test.tsx": 660,
|
||||
"src/renderer/src/components/editor/EditorFileLocationMenuItems.test.tsx": 846,
|
||||
@@ -4863,17 +4842,13 @@
|
||||
"src/renderer/src/components/editor/notebook/document/IpynbRendering.test.tsx": 2143,
|
||||
"src/renderer/src/components/editor/markdown-preview/surface/MarkdownPreview.link-routing.interaction.test.tsx": 1127,
|
||||
"src/renderer/src/components/editor/MediaViewer.test.tsx": 308,
|
||||
"src/renderer/src/components/editor/MermaidViewer.test.tsx": 3079,
|
||||
"src/renderer/src/components/editor/MonacoEditor.owner-view-state.test.tsx": 7073,
|
||||
"src/renderer/src/components/editor/PdfFind.test.tsx": 581,
|
||||
"src/renderer/src/components/editor/PluginBytesCustomEditorSurface.test.tsx": 641,
|
||||
"src/renderer/src/components/editor/PluginEditorNeedsDesktopNotice.test.tsx": 2107,
|
||||
"src/renderer/src/components/editor/PluginFileTypeSuggestion.test.tsx": 2062,
|
||||
"src/renderer/src/components/editor/rich-markdown/instance/RichMarkdownEditor.focus-leave.test.tsx": 4927,
|
||||
"src/renderer/src/components/editor/rich-markdown/instance/RichMarkdownErrorBoundary.lazy-chunk.test.tsx": 367,
|
||||
"src/renderer/src/components/editor/ai-vault-session-log-content.test.tsx": 1899,
|
||||
"src/renderer/src/components/editor/check-details/actions/check-annotation-path.test.ts": 53,
|
||||
"src/renderer/src/components/editor/check-details/reading/check-details-reading-viewport.test.ts": 259,
|
||||
"src/renderer/src/components/editor/model-lifetime/retention/closed-editor-model-lifetime.test.ts": 7921,
|
||||
"src/renderer/src/components/editor/model-lifetime/retention/closed-editor-model-shell.test.tsx": 4492,
|
||||
"src/renderer/src/components/editor/model-lifetime/retention/closed-editor-tab-disposal.test.ts": 121,
|
||||
@@ -4977,7 +4952,6 @@
|
||||
"src/renderer/src/components/editor/monaco-programmatic-sync.test.ts": 46,
|
||||
"src/renderer/src/components/editor/pdf-orca-media-range-transport.test.ts": 282,
|
||||
"src/renderer/src/components/editor/pdf-view-position.test.ts": 74,
|
||||
"src/renderer/src/components/editor/pdf-viewer-failed-load-recovery.test.tsx": 2363,
|
||||
"src/renderer/src/components/editor/pdf-viewer-zoom-ownership.test.tsx": 789,
|
||||
"src/renderer/src/components/editor/plugin-custom-editor-host.test.ts": 480,
|
||||
"src/renderer/src/components/editor/rich-markdown/raw-source/raw-markdown-html-line-break.test.ts": 2188,
|
||||
@@ -5048,17 +5022,13 @@
|
||||
"src/renderer/src/components/editor/use-monaco-editor-mount.cursor-owner.test.tsx": 1332,
|
||||
"src/renderer/src/components/editor/use-monaco-editor-mount.stale-cache.test.tsx": 877,
|
||||
"src/renderer/src/components/editor/use-monaco-reveal-scheduler.test.tsx": 273,
|
||||
"src/renderer/src/components/editor/use-pdf-viewer-find-shortcut.test.tsx": 907,
|
||||
"src/renderer/src/components/editor/use-preserve-section-during-external-edit.test.tsx": 268,
|
||||
"src/renderer/src/components/editor/rich-markdown/tables/use-rich-markdown-table-context-menu.test.tsx": 2238,
|
||||
"src/renderer/src/components/editor/useEditorPanelContentState.test.tsx": 3214,
|
||||
"src/renderer/src/components/editor/external-changes/useEditorPanelExternalContentEvents.test.tsx": 2018,
|
||||
"src/renderer/src/components/editor/useEditorPanelFloatingTabContentState.test.tsx": 889,
|
||||
"src/renderer/src/components/editor/useEditorPanelHostUnresolvedContentState.test.tsx": 1952,
|
||||
"src/renderer/src/components/editor/useEditorPanelVisibilityContentState.test.tsx": 2006,
|
||||
"src/renderer/src/components/editor/notebook/kernel/useIpynbCellExecution.test.tsx": 695,
|
||||
"src/renderer/src/components/editor/notebook/document/useIpynbDocumentEditing.test.tsx": 2192,
|
||||
"src/renderer/src/components/editor/notebook/document/useIpynbScrollRestoration.test.tsx": 323,
|
||||
"src/renderer/src/components/editor/rich-markdown/links/useLinkBubble.test.tsx": 493,
|
||||
"src/renderer/src/components/editor/rich-markdown/images/useLocalImagePick.test.tsx": 1319,
|
||||
"src/renderer/src/components/editor/document-images/useLocalImageSrc.test.ts": 736,
|
||||
@@ -5082,11 +5052,7 @@
|
||||
"src/renderer/src/components/emulator-pane/emulator-screen-stream-content.test.tsx": 408,
|
||||
"src/renderer/src/components/emulator-pane/use-emulator-pane-session.test.tsx": 1968,
|
||||
"src/renderer/src/components/emulator-pane/use-mobile-emulator-tab-intro-actions.test.tsx": 1828,
|
||||
"src/renderer/src/components/error-boundaries/RecoverableRenderErrorBoundary.lazy-chunk.test.tsx": 451,
|
||||
"src/renderer/src/components/error-boundaries/RecoverableRenderErrorBoundary.never-landed-reload.test.tsx": 449,
|
||||
"src/renderer/src/components/feature-tips/ChatUiHereCornerCard.test.tsx": 2798,
|
||||
"src/renderer/src/components/feature-tips/ChatUiHereFeatureTipVisual.test.tsx": 1093,
|
||||
"src/renderer/src/components/feature-tips/ChatUiHereTip.test.tsx": 6788,
|
||||
"src/renderer/src/components/feature-tips/feature-tip-modal-state.test.ts": 244,
|
||||
"src/renderer/src/components/feature-wall/FeatureWallSetupWorkflowActions.test.tsx": 2028,
|
||||
"src/renderer/src/components/feature-wall/FullDiskAccessSetupPrompt.test.ts": 466,
|
||||
@@ -5136,15 +5102,9 @@
|
||||
"src/renderer/src/components/mobile/WindowsFirewallNotice.test.tsx": 691,
|
||||
"src/renderer/src/components/mobile/paired-mobile-devices.test.ts": 192,
|
||||
"src/renderer/src/components/mobile/use-mobile-page-paired-devices.test.ts": 475,
|
||||
"src/renderer/src/components/native-chat-launch-resume-decision.test.tsx": 1844,
|
||||
"src/renderer/src/components/native-chat-resume-bulk-progress.test.tsx": 3261,
|
||||
"src/renderer/src/components/native-chat-resume-failed-chat-watch.test.ts": 1954,
|
||||
"src/renderer/src/components/native-chat-resume-failure-guidance.test.ts": 240,
|
||||
"src/renderer/src/components/native-chat-resume-finished-run.test.tsx": 4173,
|
||||
"src/renderer/src/components/native-chat-resume-on-restart-grouping.test.ts": 117,
|
||||
"src/renderer/src/components/native-chat-resume-result-view.test.tsx": 2723,
|
||||
"src/renderer/src/components/native-chat-resume-run.test.ts": 65,
|
||||
"src/renderer/src/components/native-chat-resume-skipped-progress.test.tsx": 3009,
|
||||
"src/renderer/src/components/native-chat-recovery/integration/native-chat-resume-bulk-progress.test.tsx": 3261,
|
||||
"src/renderer/src/components/native-chat-recovery/offers/native-chat-resume-failed-chat-watch.test.ts": 1954,
|
||||
"src/renderer/src/components/native-chat-recovery/integration/native-chat-resume-finished-run.test.tsx": 4173,
|
||||
"src/renderer/src/components/native-chat/messages/rows/NativeChatAgentMessageCard.test.tsx": 3700,
|
||||
"src/renderer/src/components/native-chat/tools/tasks/NativeChatBackgroundTaskRun.test.tsx": 242,
|
||||
"src/renderer/src/components/native-chat/tools/tasks/NativeChatBackgroundTasksStatus.test.tsx": 782,
|
||||
@@ -5156,7 +5116,7 @@
|
||||
"src/renderer/src/components/native-chat/attachments/chips/NativeChatImageAttachmentPreview.test.tsx": 2818,
|
||||
"src/renderer/src/components/native-chat/media/visuals/NativeChatInlineVisual.link-placement.test.tsx": 2477,
|
||||
"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx": 2881,
|
||||
"src/renderer/src/components/native-chat/usage/NativeChatInterruptedContinue.test.tsx": 2719,
|
||||
|
||||
"src/renderer/src/components/native-chat/viewport/scroll/NativeChatJumpToLatest.test.tsx": 477,
|
||||
"src/renderer/src/components/native-chat/markdown/code/NativeChatMarkdown.code-wrap.test.tsx": 3123,
|
||||
"src/renderer/src/components/native-chat/media/images/NativeChatMarkdown.image-preview.test.tsx": 4346,
|
||||
@@ -5173,7 +5133,6 @@
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatMessageList.test.tsx": 4252,
|
||||
"src/renderer/src/components/native-chat/conversation/turns/NativeChatMessageList.turn-indicator.test.tsx": 4070,
|
||||
"src/renderer/src/components/native-chat/conversation/slots/NativeChatMessageList.turn-membership.test.tsx": 3527,
|
||||
"src/renderer/src/components/native-chat/conversation/turns/NativeChatMessageList.turn-status.test.tsx": 3370,
|
||||
"src/renderer/src/components/native-chat/session/structured/delivery/NativeChatMessageList.unsent-message.test.tsx": 3069,
|
||||
"src/renderer/src/components/native-chat/viewport/scroll/NativeChatMessageList.visual-scroll.test.tsx": 6691,
|
||||
"src/renderer/src/components/native-chat/viewport/virtualization/NativeChatMessageList.windowing.test.tsx": 20958,
|
||||
@@ -5197,13 +5156,9 @@
|
||||
"src/renderer/src/components/native-chat/selection-quotes/NativeChatSelectionQuote.test.tsx": 2370,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.approval-and-start-failure.test.tsx": 2922,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.availability-notice.test.tsx": 2764,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.history-read-state.test.tsx": 4919,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.host-outage.test.tsx": 3552,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.notice-card.test.tsx": 2911,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.refusal-notices.test.tsx": 3014,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.retained-draft.test.tsx": 3736,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.test.tsx": 4459,
|
||||
"src/renderer/src/components/native-chat/surfaces/integration/NativeChatStructuredSession.wsl-host-stopped.test.tsx": 3657,
|
||||
"src/renderer/src/components/native-chat/tools/tasks/NativeChatStructuredSessionStatus.test.tsx": 583,
|
||||
"src/renderer/src/components/native-chat/tools/lines/NativeChatToolLine.test.tsx": 3544,
|
||||
"src/renderer/src/components/native-chat/tools/lines/NativeChatToolOutput.test.tsx": 410,
|
||||
@@ -5242,10 +5197,8 @@
|
||||
"src/renderer/src/components/native-chat/attachments/intake/native-chat-composer-drop-scope.test.tsx": 1409,
|
||||
"src/renderer/src/components/native-chat/attachments/intake/native-chat-composer-ime-file-drop.test.tsx": 1326,
|
||||
"src/renderer/src/components/native-chat/drafts/native-chat-composer-prompt-recall.test.tsx": 1724,
|
||||
"src/renderer/src/components/native-chat/composer/focus/native-chat-composer-reveal-focus.test.tsx": 526,
|
||||
"src/renderer/src/components/native-chat/attachments/intake/native-chat-composer-workspace-file-drop.test.tsx": 1166,
|
||||
"src/renderer/src/components/native-chat/drafts/native-chat-draft-retention.test.ts": 1415,
|
||||
"src/renderer/src/components/native-chat/attachments/intake/native-chat-element-file-drop.test.tsx": 2057,
|
||||
"src/renderer/src/components/native-chat/attachments/intake/native-chat-external-attachments-destination.test.tsx": 951,
|
||||
"src/renderer/src/components/native-chat/links/actions/native-chat-file-link-existence.test.ts": 1937,
|
||||
"src/renderer/src/components/native-chat/pane/actions/native-chat-header-ownership.test.tsx": 2796,
|
||||
@@ -5260,7 +5213,6 @@
|
||||
"src/renderer/src/components/native-chat/native-chat-new-rows-marker.test.tsx": 581,
|
||||
"src/renderer/src/components/native-chat/pane/routing/native-chat-open-wake.test.ts": 1807,
|
||||
"src/renderer/src/components/native-chat/pane/ownership/native-chat-owner-selectors.test.tsx": 525,
|
||||
"src/renderer/src/components/native-chat/attachments/intake/native-chat-pane-file-drop.test.tsx": 439,
|
||||
"src/renderer/src/components/native-chat/paste/native-chat-paste-routing.test.tsx": 2417,
|
||||
"src/renderer/src/components/native-chat/session/terminal/delivery/native-chat-pending.test.ts": 273,
|
||||
"src/renderer/src/components/native-chat/composer/editor/native-chat-prompt-document-text.test.ts": 219,
|
||||
@@ -5268,7 +5220,6 @@
|
||||
"src/renderer/src/components/native-chat/queue/editing/native-chat-queued-edit-draft.test.ts": 649,
|
||||
"src/renderer/src/components/native-chat/viewport/rail/native-chat-rail-outline-parity.test.ts": 497,
|
||||
"src/renderer/src/components/native-chat/viewport/scroll/native-chat-reader-scroll-input.test.tsx": 311,
|
||||
"src/renderer/src/components/native-chat/paste/native-chat-remote-image-paste.test.tsx": 1834,
|
||||
"src/renderer/src/components/native-chat/attachments/uploads/native-chat-resolved-path-ownership.test.ts": 1749,
|
||||
"src/renderer/src/components/native-chat/viewport/virtualization/native-chat-row-height-estimate.test.ts": 293,
|
||||
"src/renderer/src/components/native-chat/drafts/native-chat-sent-prompt-history.test.ts": 217,
|
||||
@@ -5278,7 +5229,6 @@
|
||||
"src/renderer/src/components/native-chat/pane/routing/native-chat-split-flow.test.ts": 1916,
|
||||
"src/renderer/src/components/native-chat/composer/submit/native-chat-structured-send-composition-clear.test.tsx": 2098,
|
||||
"src/renderer/src/components/native-chat/subagents/native-chat-subagent-handoff-copy-budget.test.ts": 362,
|
||||
"src/renderer/src/components/native-chat/subagents/native-chat-subagent-section-work-runs.test.ts": 278,
|
||||
"src/renderer/src/components/native-chat/pane/routing/native-chat-tab-directory.test.ts": 304,
|
||||
"src/renderer/src/components/native-chat/native-chat-task-list-state.test.ts": 62,
|
||||
"src/renderer/src/components/native-chat/native-chat-thread-goal-rows.test.ts": 50,
|
||||
@@ -5310,7 +5260,6 @@
|
||||
"src/renderer/src/components/native-chat/conversation/projection/use-native-chat-context-clear-floor.test.tsx": 271,
|
||||
"src/renderer/src/components/native-chat/pane/actions/use-native-chat-context-menu.targets.test.tsx": 3071,
|
||||
"src/renderer/src/components/native-chat/attachments/intake/use-native-chat-external-attachments.test.tsx": 797,
|
||||
"src/renderer/src/components/native-chat/viewport/find/use-native-chat-find.test.tsx": 1458,
|
||||
"src/renderer/src/components/native-chat/session/status/use-native-chat-hook-status.test.ts": 1927,
|
||||
"src/renderer/src/components/native-chat/host-access/use-native-chat-host-outage.test.tsx": 2131,
|
||||
"src/renderer/src/components/native-chat/drafts/use-native-chat-launch-draft-adoption.test.tsx": 319,
|
||||
@@ -5346,8 +5295,6 @@
|
||||
"src/renderer/src/components/new-workspace/DirectWorkItemSetupDialog.test.tsx": 5296,
|
||||
"src/renderer/src/components/new-workspace/NewWorkspaceComposerNameSection.test.tsx": 2493,
|
||||
"src/renderer/src/components/new-workspace/ProjectCombobox.dialog-handoff.test.tsx": 1043,
|
||||
"src/renderer/src/components/new-workspace/ProjectCombobox.test.tsx": 848,
|
||||
"src/renderer/src/components/new-workspace/ProjectComboboxRow.test.tsx": 415,
|
||||
"src/renderer/src/components/new-workspace/RunTargetCombobox.host-identity.test.tsx": 856,
|
||||
"src/renderer/src/components/new-workspace/SetProjectLocationDialog.host-identity.test.tsx": 1094,
|
||||
"src/renderer/src/components/new-workspace/SetProjectLocationDialog.test.tsx": 1387,
|
||||
@@ -5361,7 +5308,6 @@
|
||||
"src/renderer/src/components/new-workspace/use-recent-project-ids.test.ts": 1730,
|
||||
"src/renderer/src/components/new-workspace/use-smart-workspace-name-field-foundation.source.test.tsx": 2290,
|
||||
"src/renderer/src/components/new-workspace/work-item-source-selection.test.ts": 1736,
|
||||
"src/renderer/src/components/onboarding/OnboardingInlineCommandTerminal.command-finished.test.tsx": 681,
|
||||
"src/renderer/src/components/onboarding/OnboardingLanguageLoading.test.tsx": 2167,
|
||||
"src/renderer/src/components/onboarding/onboarding-feature-setup.test.ts": 76,
|
||||
"src/renderer/src/components/pet/pet-blob-cache.test.ts": 64,
|
||||
@@ -5425,7 +5371,6 @@
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/scanning/ai-vault-panel-session-list-request.test.tsx": 3044,
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/search/ai-vault-search-session.test.ts": 201,
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/accounts/ai-vault-session-account-render.test.tsx": 2885,
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/scanning/ai-vault-session-conditional-refresh-hook.test.tsx": 2370,
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/session-list/ai-vault-session-filters.test.ts": 105,
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/scope/ai-vault-session-projects.test.ts": 117,
|
||||
"src/renderer/src/components/right-sidebar/ai-vault/scanning/ai-vault-session-refresh.test.ts": 2034,
|
||||
@@ -5441,7 +5386,6 @@
|
||||
"src/renderer/src/components/right-sidebar/checks-panel/gitlab-review-client.test.ts": 321,
|
||||
"src/renderer/src/components/right-sidebar/checks-panel/comments/review-comment-markdown.test.tsx": 2171,
|
||||
"src/renderer/src/components/right-sidebar/checks-panel/refresh/use-checks-panel-manual-refresh-recovery.test.tsx": 2909,
|
||||
"src/renderer/src/components/right-sidebar/checks-panel/refresh/use-checks-panel-polling.test.tsx": 2189,
|
||||
"src/renderer/src/lib/repository-refresh/coalesced-poll-runner.test.ts": 61,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/mutations/file-explorer-delete-undo-precondition.test.tsx": 2023,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/tree/file-explorer-dir-pages.test.ts": 1767,
|
||||
@@ -5463,7 +5407,6 @@
|
||||
"src/renderer/src/components/right-sidebar/plugin-panels/health/plugin-panel-watchdog.test.ts": 116,
|
||||
"src/renderer/src/components/right-sidebar/checks-panel/comments/pr-comments-ai-launch-ack.test.ts": 118,
|
||||
"src/renderer/src/components/right-sidebar/checks-panel/comments/pr-comments-list-selection.test.tsx": 3290,
|
||||
"src/renderer/src/components/right-sidebar/right-sidebar-titlebar-drag-regions.render.test.tsx": 1044,
|
||||
"src/renderer/src/components/right-sidebar/source-control/ai/runSourceControlAgentActionStart.test.ts": 1917,
|
||||
"src/renderer/src/components/right-sidebar/source-control/review/source-control-create-pr-intent-flow.test.ts": 71,
|
||||
"src/renderer/src/components/right-sidebar/source-control/review/source-control-manual-review-url.test.ts": 77,
|
||||
@@ -5491,7 +5434,6 @@
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/mutations/useFileDeletion.save-refusal.test.tsx": 840,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/mutations/useFileDeletion.trash-failure.test.tsx": 774,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/mutations/useFileExplorerImport.committed-scope.test.tsx": 588,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/mutations/useFileExplorerImport.remote.test.tsx": 2054,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/tree/useFileExplorerTree.lifecycle.test.tsx": 1925,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/tree/useFileExplorerTree.paged-dirs.test.tsx": 2484,
|
||||
"src/renderer/src/components/right-sidebar/file-explorer/tree/useFileExplorerTree.scoped-root.test.tsx": 2131,
|
||||
@@ -5501,10 +5443,7 @@
|
||||
"src/renderer/src/components/right-sidebar/hosted-review/provider-actions/useHostedReviewStackParent.test.tsx": 288,
|
||||
"src/renderer/src/components/right-sidebar/source-control/listing/useSourceControlSubmoduleStatus.test.tsx": 2076,
|
||||
"src/renderer/src/components/settings/accounts/AccountsPane.owner-scope.test.tsx": 4057,
|
||||
"src/renderer/src/components/skills/setup/AgentSkillSetupPanel.freshness.test.tsx": 15418,
|
||||
"src/renderer/src/components/skills/setup/AgentSkillSetupPanel.plan-status.test.tsx": 23334,
|
||||
"src/renderer/src/components/skills/setup/AgentSkillSetupPanel.remote-availability.test.tsx": 5937,
|
||||
"src/renderer/src/components/skills/setup/AgentSkillSetupPanel.test.tsx": 2315,
|
||||
|
||||
"src/renderer/src/components/settings/agents/AgentsPane.test.tsx": 3230,
|
||||
"src/renderer/src/components/settings/accounts/providers/AntigravityAccountsSection.test.tsx": 2722,
|
||||
"src/renderer/src/components/settings/appearance/chat/AppearanceChatContrastControls.draft.test.tsx": 795,
|
||||
@@ -5512,10 +5451,8 @@
|
||||
"src/renderer/src/components/settings/browser/BrowserSitePermissionsSetting.test.tsx": 739,
|
||||
"src/renderer/src/components/settings/browser/BrowserUserAgentSetting.test.tsx": 2325,
|
||||
"src/renderer/src/components/settings/chat/ChatNamingSetting.test.tsx": 2454,
|
||||
"src/renderer/src/components/settings/chat/ChatPermissionSetting.test.tsx": 834,
|
||||
"src/renderer/src/components/settings/chat/ChatSettingsSection.navigation.test.tsx": 2540,
|
||||
"src/renderer/src/components/settings/chat/ChatSettingsSection.test.tsx": 2718,
|
||||
"src/renderer/src/lib/skill-runtime-command.test.ts": 1670,
|
||||
"src/renderer/src/lib/skills/runtime/skill-runtime-command.test.ts": 1670,
|
||||
"src/renderer/src/components/settings/virtual-machines/recipes/EphemeralVmsPane.test.tsx": 1025,
|
||||
"src/renderer/src/components/settings/accounts/sign-in/HostAccountSignInPrompt.test.tsx": 309,
|
||||
"src/renderer/src/components/settings/agents/launch/HostAgentLaunchSettings.test.tsx": 7498,
|
||||
@@ -5526,7 +5463,6 @@
|
||||
"src/renderer/src/components/settings/advanced/network/NodeDistMirrorDialog.test.tsx": 2412,
|
||||
"src/renderer/src/components/plugins/list/PluginsSettingsSection.lifecycle.test.tsx": 5402,
|
||||
"src/renderer/src/components/settings/runtime-environments/pairing/RuntimePairingGeneratorForm.test.tsx": 461,
|
||||
"src/renderer/src/components/settings/session-history/SessionHistorySettingsPane.test.tsx": 1474,
|
||||
"src/renderer/src/components/settings/appearance/fonts/FontAutocomplete.test.tsx": 1202,
|
||||
"src/renderer/src/components/settings/form-controls/SettingsFormControls.segmented-control.test.tsx": 730,
|
||||
"src/renderer/src/components/settings/shortcuts/ShortcutFilterRail.test.ts": 273,
|
||||
@@ -5541,12 +5477,9 @@
|
||||
"src/renderer/src/components/settings/TerminalAppearanceSection.ghostty.test.ts": 549,
|
||||
"src/renderer/src/components/settings/terminal/appearance/TerminalContrastSetting.test.tsx": 798,
|
||||
"src/renderer/src/components/settings/terminal/session-management/TerminalLimitSetting.test.tsx": 1015,
|
||||
"src/renderer/src/components/settings/terminal/TerminalPane.section-lifetime.test.tsx": 1237,
|
||||
"src/renderer/src/components/settings/terminal/appearance/TerminalSettingsPreview.lifecycle.test.tsx": 595,
|
||||
"src/renderer/src/components/settings/developer-permissions/TerminalTccAttributionNotice.test.tsx": 401,
|
||||
"src/renderer/src/components/settings/voice/VoiceMicrophoneSetting.test.tsx": 957,
|
||||
"src/renderer/src/components/settings/voice/VoicePane.test.tsx": 1042,
|
||||
"src/renderer/src/components/settings/voice/VoiceSpeechModelSection.test.tsx": 503,
|
||||
"src/renderer/src/components/settings/accounts/sign-in/account-add-cancel-target.test.ts": 217,
|
||||
"src/renderer/src/components/settings/accounts/usage/accounts-pane-opencode-credentials.test.ts": 519,
|
||||
"src/renderer/src/lib/agent-session/launch/agent-settings-update-queue.test.ts": 249,
|
||||
@@ -5556,7 +5489,6 @@
|
||||
"src/renderer/src/components/settings/developer-permissions/developer-permissions-search.test.ts": 308,
|
||||
"src/renderer/src/components/settings/shortcuts/keybinding-diagnostic-text.test.ts": 522,
|
||||
"src/renderer/src/components/settings/shortcuts/keybinding-title-copy.test.ts": 227,
|
||||
"src/renderer/src/lib/agent-session/launch/native-chat-provider-choice.test.tsx": 3738,
|
||||
"src/renderer/src/components/settings/notifications/notification-host-pending-save.test.tsx": 2029,
|
||||
"src/renderer/src/components/settings/repository/RepositoryJiraProjectSection.test.tsx": 463,
|
||||
"src/renderer/src/components/settings/repository/RepositoryPaneDraftInput.test.tsx": 314,
|
||||
@@ -5578,10 +5510,7 @@
|
||||
"src/renderer/src/components/settings/runtime-environments/catalog/use-runtime-environment-mutation-actions.test.tsx": 2069,
|
||||
"src/renderer/src/components/session-search/use-session-search-status.test.tsx": 477,
|
||||
"src/renderer/src/components/settings/accounts/usage/use-zcode-plan-credentials.test.tsx": 880,
|
||||
"src/renderer/src/lib/directory-path-suggestion-filter.scan-budget.test.ts": 68,
|
||||
"src/renderer/src/lib/directory-path-suggestion-filter.test.ts": 51,
|
||||
"src/renderer/src/components/setup-guide/SetupGuideModal.mount-gating.test.tsx": 2348,
|
||||
"src/renderer/src/components/shared/MacFolderAccessFixDialog.test.tsx": 1356,
|
||||
"src/renderer/src/components/shared/kill-all-terminal-surfaces.test.ts": 1925,
|
||||
"src/renderer/src/components/shared/useDaemonActions.test.tsx": 332,
|
||||
"src/renderer/src/components/sidebar/host-admission/ssh/AddRemoteHostDialog.config-picker.test.tsx": 1178,
|
||||
@@ -5603,7 +5532,6 @@
|
||||
"src/renderer/src/components/sidebar/SeveredTerminalDaemonBanner.test.tsx": 574,
|
||||
"src/renderer/src/components/sidebar/Sidebar.test.tsx": 833,
|
||||
"src/renderer/src/components/sidebar/SidebarAgentsList.test.tsx": 2985,
|
||||
"src/renderer/src/components/sidebar/sidebar-feedback/SidebarFeedbackDialog.test.tsx": 2529,
|
||||
"src/renderer/src/components/sidebar/StalledTerminalDaemonBanner.test.tsx": 320,
|
||||
"src/renderer/src/components/sidebar/workspace-board/viewport/WorkspaceKanbanLaneGrid.test.tsx": 360,
|
||||
"src/renderer/src/components/sidebar/workspace-card/surface/WorktreeCard.single-reference-details.test.tsx": 2032,
|
||||
@@ -5689,7 +5617,6 @@
|
||||
"src/renderer/src/components/sidebar/worktree-list/rows/repo-header-ssh-isolation.test.tsx": 2945,
|
||||
"src/renderer/src/components/sidebar/worktree-list/rows/section-header-create-host.test.tsx": 2393,
|
||||
"src/renderer/src/components/sidebar/worktree-list/viewport/hard-scroll-up.test.ts": 66,
|
||||
"src/renderer/src/components/sidebar/worktree-list/viewport/header-folder-composition.test.tsx": 3725,
|
||||
"src/renderer/src/components/sidebar/worktree-list/viewport/use-scroll-to-top.test.ts": 293,
|
||||
"src/renderer/src/components/sidebar/worktree-list/viewport/use-scroll-to-top.test.tsx": 269,
|
||||
"src/renderer/src/components/sidebar/worktree-list/drag/worktree-manual-order-store-write.test.ts": 2144,
|
||||
@@ -5697,22 +5624,17 @@
|
||||
"src/renderer/src/components/sidebar/workspace-actions/parenting/worktree-parent-eligibility.test.ts": 68,
|
||||
"src/renderer/src/components/sidebar/worktree-list/listing/worktree-sort-label-ordering.test.ts": 114,
|
||||
"src/renderer/src/components/sidebar/wsl-host-offer-move.test.ts": 227,
|
||||
"src/renderer/src/components/skills/SkillFreshnessUpdateDialog.test.tsx": 913,
|
||||
"src/renderer/src/components/skills/SkillInstallDialog.test.tsx": 4429,
|
||||
"src/renderer/src/components/skills/SkillInstallManagementDialog.test.tsx": 3300,
|
||||
"src/renderer/src/components/skills/SkillSharedLinkRow.test.tsx": 817,
|
||||
|
||||
"src/renderer/src/components/skills/installation/SkillInstallManagementDialog.test.tsx": 3300,
|
||||
"src/renderer/src/components/skills/sharing/SkillSharedLinkRow.test.tsx": 817,
|
||||
"src/renderer/src/components/skills/SkillsPage.test.tsx": 3822,
|
||||
"src/renderer/src/components/skills/skill-agent-filter.test.ts": 274,
|
||||
"src/renderer/src/components/skills/skill-share-link.test.ts": 55,
|
||||
"src/renderer/src/components/skills/skill-share-package-selection.test.ts": 49,
|
||||
"src/renderer/src/components/skills/skills-filter.test.ts": 204,
|
||||
"src/renderer/src/components/skills/catalog/skill-agent-filter.test.ts": 274,
|
||||
|
||||
"src/renderer/src/components/sparse/sparse-directory-entry-input.test.ts": 207,
|
||||
"src/renderer/src/components/stats/usage-daily-chart.test.tsx": 333,
|
||||
"src/renderer/src/components/stats/usage-overview-model.test.ts": 364,
|
||||
"src/renderer/src/components/status-bar/ClaudeSwitcherMenu.owner-lifetime.test.tsx": 2317,
|
||||
"src/renderer/src/components/status-bar/NativeChatResumeStatusSegment.test.tsx": 2452,
|
||||
"src/renderer/src/components/status-bar/PortsStatusSegment.render-stability.test.tsx": 2161,
|
||||
"src/renderer/src/components/status-bar/SkillUpdateStatusSegment.test.tsx": 594,
|
||||
|
||||
"src/renderer/src/components/status-bar/SshStatusSegment.large-host-list.test.tsx": 1838,
|
||||
"src/renderer/src/components/status-bar/StatusBarUsageChangeNotices.test.tsx": 785,
|
||||
"src/renderer/src/components/status-bar/UpdateStatusSegment.test.tsx": 2484,
|
||||
@@ -5733,7 +5655,6 @@
|
||||
"src/renderer/src/components/status-bar/use-resource-pty-actions.test.tsx": 879,
|
||||
"src/renderer/src/components/status-bar/use-resource-usage-derived-model.test.tsx": 742,
|
||||
"src/renderer/src/components/tab-bar/CopyTabIdMenuItem.test.tsx": 428,
|
||||
"src/renderer/src/components/tab-bar/NativeChatNamingFailure.test.tsx": 1062,
|
||||
"src/renderer/src/components/tab-bar/TabBarCreateEntry.search.test.tsx": 3224,
|
||||
"src/renderer/src/components/tab-bar/TabBarItemRow.test.tsx": 2116,
|
||||
"src/renderer/src/components/tab-bar/TabBarQuickCommandItem.test.tsx": 384,
|
||||
@@ -5752,7 +5673,6 @@
|
||||
"src/renderer/src/components/tab-bar/tab-context-menu.test.tsx": 5620,
|
||||
"src/renderer/src/components/tab-bar/tab-create-entry-classifier.test.ts": 510,
|
||||
"src/renderer/src/components/tab-bar/tab-create-entry-local-path.test.ts": 2614,
|
||||
"src/renderer/src/components/tab-bar/tab-create-entry-preview.test.ts": 882,
|
||||
"src/renderer/src/components/tab-bar/tab-session-history-switch.test.ts": 2348,
|
||||
"src/renderer/src/components/tab-bar/tab-strip-growth-scroll.test.tsx": 2164,
|
||||
"src/renderer/src/components/tab-bar/tab-strip-pointer-activation.test.tsx": 2047,
|
||||
@@ -5808,10 +5728,6 @@
|
||||
"src/renderer/src/components/task-page/use-task-page-source-display.test.tsx": 5228,
|
||||
"src/renderer/src/components/terminal-pane/layout/close/RunningTerminalCloseDialog.test.tsx": 2303,
|
||||
"src/renderer/src/components/terminal-pane/session-fork/TerminalAgentSessionForkDialog.test.tsx": 266,
|
||||
"src/renderer/src/components/terminal-pane/titles/TerminalPaneHeaderOverlay.test.tsx": 1104,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/recovery/TerminalPaneRecoveryPortals.test.tsx": 670,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/recovery/TerminalRemoteRuntimeReconnectBanner.test.tsx": 812,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/recovery/ssh/TerminalSshReconnectOverlay.test.tsx": 2354,
|
||||
"src/renderer/src/components/terminal-pane/account-restart/detached/account-restart-queue-progress.test.ts": 1988,
|
||||
"src/renderer/src/components/terminal-pane/agent-completion/agent-completion-coordinator-attention-dispatch.test.ts": 301,
|
||||
"src/renderer/src/components/terminal-pane/agent-completion/agent-completion-coordinator-completion-replay-guard.test.ts": 318,
|
||||
@@ -5861,7 +5777,6 @@
|
||||
"src/renderer/src/components/terminal-pane/layout/close/pending-pane-close-confirmation.test.ts": 4695,
|
||||
"src/renderer/src/components/terminal-pane/layout/close/pending-runtime-pane-close.test.ts": 3487,
|
||||
"src/renderer/src/components/terminal-pane/layout/close/pending-split-close.test.ts": 4680,
|
||||
"tests/e2e/terminal-agent-pane-launch.unit.test.ts": 8045,
|
||||
"src/renderer/src/components/terminal-pane/snapshots/pty-buffer-serializer.test.ts": 53,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/agent-identity/pty-connection-command-finished-late-done.test.ts": 10940,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/tests/pty-connection-completion-and-notification.test.ts": 18380,
|
||||
@@ -5885,7 +5800,6 @@
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output-restore/pty-connection-post-dispose-restore-termination.test.ts": 1215,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/agent-identity/pty-connection-process-exit-row-retire.test.ts": 10626,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/host-ownership/pty-connection-owner-hydration-backend-retention.test.ts": 4181,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/startup/pty-connection-queued-startup-consume.test.ts": 4181,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/reattach/pty-connection-reattach-binding.test.ts": 5240,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/input/pty-connection-remote-new-terminal-typeahead.test.ts": 1864,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/reattach/pty-connection-remote-snapshot-image-title.test.ts": 1754,
|
||||
@@ -5893,7 +5807,6 @@
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output-restore/pty-connection-restored-baseline-shortfall.test.ts": 1902,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/tests/pty-connection-spawn-and-startup.test.ts": 19652,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/spawn/pty-connection-spawn-deferred-sleep.test.ts": 6918,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/startup/pty-connection-split-cwd-resolution.test.ts": 2139,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/tests/pty-connection-visibility-and-exit.test.ts": 18950,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output-restore/pty-connection-visible-pane-output-pause-latch.test.ts": 1639,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/reattach/deferred-session-reattach-newer-daemon-hold.test.ts": 2570,
|
||||
@@ -5902,18 +5815,15 @@
|
||||
"src/shared/terminal/protocol/escape/terminal-synchronized-output-socket-splits.test.ts": 92,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output/foreground-renderer-risk-scan-tail.test.ts": 111,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/spawn/hidden-agent-resume-deferral.test.ts": 55,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/startup/in-place-resume-hold-wiring.test.ts": 2484,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/startup/main-pane-resume-banner.test.ts": 59,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/spawn/main-pane-start-wait.test.ts": 76,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/serialization/pane-serializer-register.test.ts": 123,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/host-ownership/pty-kitty-file-reader.test.ts": 297,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/startup/saved-resume-cancellation.test.ts": 1882,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output-restore/snapshot-covered-terminal-queries.test.ts": 150,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output/terminal-input-echo-delay.test.ts": 132,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/host-ownership/unserved-ssh-pane-bridge.test.ts": 70,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/delivery/pty-dispatcher-delivery-resync.test.ts": 85,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/delivery/pty-dispatcher-pi-routing.test.ts": 1362,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/delivery/pty-dispatcher-push-reattach.test.ts": 108,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/input/pty-input-write-queue.test.ts": 787,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/delivery/pty-model-restore-channel.test.ts": 44,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/output/pty-output-processor-program-activity.test.ts": 160,
|
||||
@@ -5926,7 +5836,6 @@
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/shutdown/pty-shutdown-exit-deferral.test.ts": 121,
|
||||
"src/renderer/src/components/terminal-pane/viewport/pty-size-reassertion.test.ts": 58,
|
||||
"src/renderer/src/components/terminal-pane/viewport/pty-size-reconcile.test.ts": 68,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-connect-spawn.test.ts": 3186,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-detach-attach-handoff.test.ts": 1199,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-eager-buffer-replay.test.ts": 1636,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-handler-suspension.test.ts": 1243,
|
||||
@@ -5935,7 +5844,6 @@
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-pi-coalesce.test.ts": 683,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-reattach-admission.test.ts": 1636,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-recycled-pty-incarnation.test.ts": 787,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/ipc/pty-transport-spawn-errors.test.ts": 1218,
|
||||
"src/renderer/src/components/terminal-pane/input/focus/regular-terminal-focus-ownership.test.ts": 208,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output-restore/remote-hidden-output-restore-outcomes.test.ts": 2794,
|
||||
"src/renderer/src/components/terminal-pane/pty-connection/output-restore/remote-hidden-output-restore-unavailable-banner.repro.test.ts": 2355,
|
||||
@@ -5952,7 +5860,6 @@
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-query-reply-immediate.test.ts": 1556,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/recovery/remote-runtime-pty-recovery-state.test.ts": 85,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-transport-activation-inventory-fallback.test.ts": 1311,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-transport-attach-subscription.test.ts": 2346,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-transport-create-handoff.test.ts": 14353,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-transport-create-outcome-recovery.test.ts": 2041,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-transport-empty-initial-snapshot.test.ts": 1491,
|
||||
@@ -6001,14 +5908,9 @@
|
||||
"src/renderer/src/components/terminal-pane/input/paste/terminal-bracketed-paste.test.ts": 57,
|
||||
"src/renderer/src/components/terminal-pane/emulation/terminal-capability-replies.test.ts": 131,
|
||||
"src/renderer/src/components/terminal-pane/clipboard/terminal-clipboard-paste.test.ts": 76,
|
||||
"src/renderer/src/components/terminal-pane/parking/retention/terminal-cold-park-timer-rearm.test.tsx": 701,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/delivery/terminal-delivery-watchdog.test.ts": 111,
|
||||
"src/renderer/src/components/terminal-pane/input/file-drop/terminal-drop-handler.test.ts": 638,
|
||||
"src/renderer/src/components/terminal-pane/input/file-drop/terminal-drop-image-path.test.ts": 61,
|
||||
"src/renderer/src/components/terminal-pane/input/file-drop/terminal-drop-internal-handler.test.ts": 800,
|
||||
"src/renderer/src/components/terminal-pane/input/file-drop/terminal-drop-path-writer.test.ts": 245,
|
||||
"src/renderer/src/components/terminal-pane/input/file-drop/terminal-drop-runtime-catalog-owner.test.ts": 872,
|
||||
"src/renderer/src/components/terminal-pane/input/file-drop/terminal-drop-source-owner.test.ts": 622,
|
||||
"src/renderer/src/components/terminal-pane/viewport/terminal-fit-restore.test.ts": 59,
|
||||
"src/renderer/src/components/terminal-pane/links/handles/terminal-handle-links.test.ts": 527,
|
||||
"src/renderer/src/components/terminal-pane/parking/retention/terminal-hidden-view-parking.test.ts": 325,
|
||||
@@ -6041,7 +5943,6 @@
|
||||
"src/shared/workspace-layout/terminal-layout-pty-ownership-depth.test.ts": 82,
|
||||
"src/renderer/src/components/terminal-pane/layout/terminal-layout-pty-ownership.test.ts": 99,
|
||||
"src/renderer/src/components/terminal-pane/links/terminal-link-click-fallback.test.ts": 985,
|
||||
"src/renderer/src/components/terminal-pane/links/files/terminal-link-file-open-routing.test.ts": 970,
|
||||
"src/renderer/src/components/terminal-pane/links/terminal-link-open-beside-source.test.ts": 947,
|
||||
"src/renderer/src/components/terminal-pane/links/http/terminal-link-osc-url-routing.test.ts": 986,
|
||||
"src/renderer/src/components/terminal-pane/links/terminal-link-paired-click-fallback.test.ts": 989,
|
||||
@@ -6059,14 +5960,11 @@
|
||||
"src/renderer/src/components/terminal-pane/layout/reconciliation/terminal-pane-frame-reconciliation.test.ts": 903,
|
||||
"src/renderer/src/components/terminal-pane/host-state/terminal-pane-host-state-memo.test.ts": 4534,
|
||||
"src/renderer/src/components/terminal-pane/mounting/terminal-pane-mount-bootstrap.test.ts": 1723,
|
||||
"src/renderer/src/components/terminal-pane/render-health/recovery/terminal-pane-recovery-unsettled-fallback.test.ts": 831,
|
||||
"src/renderer/src/components/terminal-pane/render-health/recovery/terminal-pane-recovery.test.ts": 949,
|
||||
"src/renderer/src/components/terminal-pane/layout/split/terminal-pane-split-request-routing.test.ts": 2015,
|
||||
"src/renderer/src/components/terminal-pane/pty-transport/recovery/terminal-pane-surface-ownership.test.ts": 426,
|
||||
"src/renderer/src/components/terminal-pane/layout/detach/terminal-pane-tab-detach-main-commit.test.ts": 2090,
|
||||
"src/renderer/src/components/terminal-pane/layout/detach/terminal-pane-tab-detach-main-move.test.ts": 2147,
|
||||
"src/renderer/src/components/terminal-pane/parking/verdict/terminal-park-verdict-flip-telemetry.test.ts": 123,
|
||||
"src/renderer/src/components/terminal-pane/parking/verdict/terminal-park-verdict-worktree-driver-loop.test.tsx": 735,
|
||||
"src/renderer/src/components/terminal-pane/parking/output-watchers/terminal-parked-tab-watchers.test.ts": 473,
|
||||
"src/renderer/src/components/terminal-pane/parking/output-watchers/terminal-parked-watcher-reconciliation.test.ts": 243,
|
||||
"src/renderer/src/components/terminal-pane/parking/output-watchers/terminal-parked-watcher-registry.test.ts": 245,
|
||||
@@ -6188,8 +6086,7 @@
|
||||
"src/renderer/src/hooks/editor-external-watch-overflow.test.ts": 1023,
|
||||
"src/renderer/src/hooks/editor-external-watch-selected-host.test.ts": 1988,
|
||||
"src/renderer/src/hooks/editor-runtime-file-watch.test.ts": 58,
|
||||
"src/renderer/src/hooks/installed-agent-skill-discovery-cache.test.ts": 53,
|
||||
"src/renderer/src/hooks/installed-agent-skill-discovery.test.ts": 74,
|
||||
|
||||
"src/renderer/src/hooks/ipc-events/agent-status-pane-routing-index-retention.test.ts": 4878,
|
||||
"src/renderer/src/hooks/ipc-events/agent-status-pending-retry-gate.test.ts": 466,
|
||||
"src/renderer/src/hooks/ipc-events/agent-status-terminal-title-tab-write.test.ts": 2247,
|
||||
@@ -6226,7 +6123,7 @@
|
||||
"src/renderer/src/hooks/runtime-project-refresh-scheduler.test.ts": 65,
|
||||
"src/renderer/src/hooks/shortcut-label-cache.test.tsx": 2021,
|
||||
"src/renderer/src/hooks/unpaired-device-auth-notification.test.ts": 41,
|
||||
"src/renderer/src/hooks/use-bundled-skill-install.test.tsx": 553,
|
||||
|
||||
"src/renderer/src/hooks/use-document-dark-theme.test.tsx": 350,
|
||||
"src/renderer/src/hooks/use-list-multi-selection.test.tsx": 545,
|
||||
"src/renderer/src/hooks/use-monaco-theme.test.tsx": 323,
|
||||
@@ -6252,9 +6149,8 @@
|
||||
"src/renderer/src/hooks/useEphemeralVmRecipeOptions.test.tsx": 415,
|
||||
"src/renderer/src/hooks/useGitHubSlugMetadata.assignee-reuse.test.tsx": 233,
|
||||
"src/renderer/src/hooks/useImmediateMutation.test.ts": 618,
|
||||
"src/renderer/src/hooks/useInstalledAgentSkills.react.test.tsx": 2093,
|
||||
"src/renderer/src/hooks/skills/discovery/useInstalledAgentSkills.react.test.tsx": 2093,
|
||||
"src/renderer/src/hooks/useIpcEvents-agent-status-connection-attribution.test.ts": 5510,
|
||||
"src/renderer/src/hooks/useIpcEvents-agent-status-hook-titles.test.ts": 5621,
|
||||
"src/renderer/src/hooks/useIpcEvents-agent-status-pane-teardown.test.ts": 5268,
|
||||
"src/renderer/src/hooks/useIpcEvents-agent-status-queue-ordering.test.ts": 3680,
|
||||
"src/renderer/src/hooks/useIpcEvents-agent-status-snapshot-hydration.test.ts": 7403,
|
||||
@@ -6268,15 +6164,13 @@
|
||||
"src/renderer/src/hooks/useIpcEvents-cmd-j-digit-chord.test.ts": 2703,
|
||||
"src/renderer/src/hooks/useIpcEvents-lifecycle.test.ts": 2326,
|
||||
"src/renderer/src/hooks/useIpcEvents-new-workspace-shortcut.test.ts": 72,
|
||||
"src/renderer/src/hooks/useIpcEvents-rate-limit-hydration.test.ts": 1597,
|
||||
"src/renderer/src/hooks/useIpcEvents-runtime-environment-selectors.test.ts": 530,
|
||||
"src/renderer/src/hooks/useIpcEvents-session-tab-close-request.test.ts": 2252,
|
||||
"src/renderer/src/hooks/useIssueMetadata.test.tsx": 344,
|
||||
"src/renderer/src/hooks/useMacTccAttributionSeveredNotice.test.tsx": 2358,
|
||||
"src/renderer/src/hooks/useMetadataListRequest.test.tsx": 266,
|
||||
"src/renderer/src/hooks/useModalReturnFocus.test.tsx": 1938,
|
||||
"src/renderer/src/hooks/usePrimarySelectionPaste.terminal-native-paste.test.tsx": 388,
|
||||
"src/renderer/src/hooks/usePrimarySelectionPaste.test.tsx": 411,
|
||||
"src/renderer/src/hooks/clipboard/primary-selection/usePrimarySelectionPaste.terminal-native-paste.test.tsx": 388,
|
||||
"src/renderer/src/hooks/clipboard/primary-selection/usePrimarySelectionPaste.test.tsx": 411,
|
||||
"src/renderer/src/hooks/useReadOnScreenAttention.away.test.ts": 2420,
|
||||
"src/renderer/src/hooks/useReadOnScreenAttention.clock-skew.test.ts": 2093,
|
||||
"src/renderer/src/hooks/useReadOnScreenAttention.floating-panel.test.ts": 2157,
|
||||
@@ -6284,7 +6178,7 @@
|
||||
"src/renderer/src/hooks/useReadOnScreenAttention.mixed-workspace.test.ts": 1725,
|
||||
"src/renderer/src/hooks/useReadOnScreenAttention.test.ts": 1915,
|
||||
"src/renderer/src/hooks/useRetiredWorktreeNames.test.ts": 593,
|
||||
"src/renderer/src/hooks/useSkillFreshness.test.tsx": 554,
|
||||
|
||||
"src/renderer/src/hooks/useUnreadDockBadge.test.ts": 2126,
|
||||
"src/renderer/src/hooks/virtualized-hidden-row-measurement.test.ts": 199,
|
||||
"src/renderer/src/hooks/worktree-change-refresh-queue.test.ts": 59,
|
||||
@@ -6308,8 +6202,6 @@
|
||||
"src/renderer/src/lib/agent-session/hibernation/agent-hibernation-pane-age.test.ts": 41,
|
||||
"src/renderer/src/lib/agent-session/hibernation/agent-hibernation-planner.test.ts": 341,
|
||||
"src/renderer/src/lib/agent-session/hibernation/agent-hibernation-runtime-liveness-race.test.ts": 1914,
|
||||
"src/renderer/src/lib/agent-session/launch/new-tab/agent-launch-caller-prompt-transport.test.ts": 1326,
|
||||
"src/renderer/src/lib/agent-session/launch/new-tab/agent-launch-caller-routing.test.ts": 1266,
|
||||
"src/renderer/src/lib/agent-session/launch/pane/agent-launch-pane-verdict-application.test.ts": 1869,
|
||||
"src/renderer/src/lib/agent-session/launch/routing/agent-launch-route-input.test.ts": 1659,
|
||||
"src/renderer/src/lib/agent-session/launch/routing/agent-launch-route-registered-agents.test.ts": 1749,
|
||||
@@ -6350,9 +6242,9 @@
|
||||
"src/renderer/src/lib/agent-session/resume/history/ai-vault-session-resume-preparation.test.ts": 408,
|
||||
"src/renderer/src/lib/agent-session/history/title-sync/ai-vault-tab-title-sync-inputs.test.ts": 476,
|
||||
"src/renderer/src/lib/agent-session/history/title-sync/ai-vault-tab-title-sync.test.ts": 925,
|
||||
"src/renderer/src/lib/app-command-dispatch.test.ts": 64,
|
||||
"src/renderer/src/lib/app-keyboard-router.test.ts": 187,
|
||||
"src/renderer/src/lib/app-menu-paste.test.ts": 229,
|
||||
"src/renderer/src/lib/app-commands/app-command-dispatch.test.ts": 64,
|
||||
"src/renderer/src/lib/keyboard/app-keyboard-router.test.ts": 187,
|
||||
"src/renderer/src/lib/clipboard/menu/app-menu-paste.test.ts": 229,
|
||||
"src/renderer/src/lib/automation-session-reuse.test.ts": 70,
|
||||
"src/renderer/src/lib/automation-terminal-ownership.test.ts": 1795,
|
||||
"src/renderer/src/lib/bounded-generation-map.test.ts": 35,
|
||||
@@ -6363,12 +6255,12 @@
|
||||
"src/renderer/src/lib/browser/navigation/browser-link-profile-isolation.test.ts": 2511,
|
||||
"src/renderer/src/lib/browser/palette/browser-page-palette-activation.test.ts": 1983,
|
||||
"src/renderer/src/lib/browser/palette/browser-palette-page-entries.test.ts": 480,
|
||||
"src/renderer/src/lib/bundled-skill-target.test.ts": 54,
|
||||
"src/renderer/src/lib/skills/runtime/bundled-skill-target.test.ts": 54,
|
||||
"src/renderer/src/lib/source-control/checks/check-run-details-log-normalization-performance.test.ts": 846,
|
||||
"src/renderer/src/lib/source-control/checks/check-run-details-log-normalization.test.ts": 75,
|
||||
"src/renderer/src/lib/claude-account-switch-sessions.test.ts": 782,
|
||||
"src/renderer/src/lib/claude-session-account-move.test.ts": 1816,
|
||||
"src/renderer/src/lib/clipboard-image-copy.test.ts": 243,
|
||||
"src/renderer/src/lib/clipboard/images/clipboard-image-copy.test.ts": 243,
|
||||
"src/renderer/src/lib/cmd-j-host-qualified-candidate-ownership.test.ts": 526,
|
||||
"src/renderer/src/lib/cmd-j-linear-issue-intent.test.ts": 42,
|
||||
"src/renderer/src/lib/code-host-error-copy.test.ts": 297,
|
||||
@@ -6377,11 +6269,9 @@
|
||||
"src/renderer/src/lib/agent-session/accounts/codex/codex-session-restart.test.ts": 2039,
|
||||
"src/renderer/src/lib/codex-stale-pane-account-identity.test.ts": 1823,
|
||||
"src/renderer/src/lib/codex-stale-pane-sweep.test.ts": 1817,
|
||||
"src/renderer/src/lib/comment-body-line-count.test.ts": 84,
|
||||
"src/renderer/src/lib/comment-body-submit-state.test.ts": 55,
|
||||
"src/renderer/src/lib/source-control/review/comments/comment-body-submit-state.test.ts": 55,
|
||||
"src/renderer/src/lib/composer-submit-cancellation.test.ts": 41,
|
||||
"src/renderer/src/lib/workspace/ownership/connection-context.test.ts": 1817,
|
||||
"src/renderer/src/lib/crash-diagnostics.test.ts": 176,
|
||||
"src/renderer/src/lib/create-untitled-markdown.test.ts": 566,
|
||||
"src/renderer/src/lib/desktop-created-server-tabs.test.ts": 1933,
|
||||
"src/renderer/src/lib/workspace/ownership/direct-ssh-target-scope.test.ts": 48,
|
||||
@@ -6390,32 +6280,23 @@
|
||||
"src/renderer/src/lib/browser/documents/doc-preview-grants.test.ts": 2094,
|
||||
"src/renderer/src/lib/editor/file-operations/editor-file-operation-owner.test.ts": 2848,
|
||||
"src/renderer/src/lib/emulator-error-copy.test.ts": 415,
|
||||
"src/renderer/src/lib/ensure-hooks-confirmed.test.ts": 799,
|
||||
"src/renderer/src/runtime/repo-hooks/ensure-hooks-confirmed.test.ts": 799,
|
||||
"src/renderer/src/lib/simulator/tabs/ensure-simulator-tab-behavior.test.ts": 3601,
|
||||
"src/renderer/src/runtime/hosts/platform/execution-host-facts.test.ts": 1796,
|
||||
"src/renderer/src/lib/feature-education-telemetry.test.ts": 52,
|
||||
"src/renderer/src/lib/feedback-image-attachments.test.ts": 557,
|
||||
"src/renderer/src/lib/browser/documents/file-preview-link-open.test.ts": 2311,
|
||||
"src/renderer/src/lib/file-search-selection.test.ts": 51,
|
||||
"src/renderer/src/lib/find-query-bounds.test.ts": 45,
|
||||
"src/renderer/src/components/sidebar/sidebar-feedback/feedback-image-attachments.test.ts": 557,
|
||||
"src/renderer/src/lib/files/search/file-search-selection.test.ts": 51,
|
||||
"src/renderer/src/lib/finished-agent-resume-resurrection.test.ts": 1872,
|
||||
"src/renderer/src/lib/focus-terminal-tab-surface.split-focus.test.ts": 331,
|
||||
"src/renderer/src/lib/foreground-terminal-tabs.test.ts": 55,
|
||||
"src/renderer/src/lib/github-links.test.ts": 76,
|
||||
"src/renderer/src/lib/github-source-runtime-context.test.ts": 62,
|
||||
"src/renderer/src/lib/gitlab-links.test.ts": 56,
|
||||
"src/renderer/src/lib/hook-command-delayed-delivery.test.ts": 1904,
|
||||
"src/renderer/src/lib/host-chat-program.test.ts": 2419,
|
||||
"src/renderer/src/components/terminal-pane/parking/retention/foreground-terminal-tabs.test.ts": 55,
|
||||
"src/renderer/src/lib/work-items/github/github-source-runtime-context.test.ts": 62,
|
||||
"src/renderer/src/lib/host-mirror-handle-gap-drain.test.ts": 1706,
|
||||
"src/renderer/src/lib/host-mirror-handle-gap-resume.test.ts": 1811,
|
||||
"src/renderer/src/lib/host-mirrored-pane-resume-replay.test.ts": 1814,
|
||||
"src/renderer/src/lib/browser/navigation/http-link-completion.test.ts": 1760,
|
||||
"src/renderer/src/lib/browser/navigation/http-link-routing-store.test.ts": 2211,
|
||||
"src/renderer/src/lib/image-blob-png.test.ts": 253,
|
||||
"src/renderer/src/lib/ime-composition-keyboard-event.test.ts": 274,
|
||||
"src/renderer/src/lib/ime-text-field.test.tsx": 739,
|
||||
"src/renderer/src/lib/text-input/ime/ime-composition-keyboard-event.test.ts": 274,
|
||||
"src/renderer/src/lib/text-input/ime/ime-text-field.test.tsx": 739,
|
||||
"src/renderer/src/lib/keyboard-layout/layout-base-character.test.ts": 48,
|
||||
"src/renderer/src/lib/large-text-control-paste.test.ts": 220,
|
||||
"src/renderer/src/lib/text-input/paste/large-text-control-paste.test.ts": 220,
|
||||
"src/renderer/src/lib/agent-session/launch/background/launch-agent-background-session-launch-parity.test.ts": 2792,
|
||||
"src/renderer/src/lib/agent-session/launch/background/launch-agent-background-session.test.ts": 1040,
|
||||
"src/renderer/src/lib/agent-session/launch/new-tab/launch-agent-in-new-tab-main-surface.test.ts": 1821,
|
||||
@@ -6428,15 +6309,11 @@
|
||||
"src/renderer/src/lib/workspace/creation/work-item/launch-work-item-direct-accepted.test.tsx": 2754,
|
||||
"src/renderer/src/lib/workspace/creation/work-item/launch-work-item-direct-defaults.test.ts": 1594,
|
||||
"src/renderer/src/lib/workspace/creation/work-item/launch-work-item-direct-setup.test.tsx": 3435,
|
||||
"src/renderer/src/lib/lazy-chunk-recovery-reload.test.ts": 246,
|
||||
"src/renderer/src/lib/lazy-with-retry.never-landed-reload.test.ts": 194,
|
||||
"src/renderer/src/lib/lazy-with-retry.preload.test.tsx": 208,
|
||||
"src/renderer/src/lib/lazy-with-retry.test.ts": 282,
|
||||
"src/renderer/src/lib/linear-board-drag-payload.test.ts": 58,
|
||||
"src/renderer/src/lib/work-items/linear/linear-issue-context-snapshot.test.ts": 55,
|
||||
"src/renderer/src/app-shell/startup/lazy-with-retry.never-landed-reload.test.ts": 194,
|
||||
"src/renderer/src/lib/work-items/linear/linear-board-drag-payload.test.ts": 58,
|
||||
"src/renderer/src/lib/work-items/linear/linear-issue-workspace-attachment.test.ts": 99,
|
||||
"src/renderer/src/lib/link-source-local-open-owner.test.ts": 433,
|
||||
"src/renderer/src/lib/linked-work-item-context.test.ts": 64,
|
||||
"src/renderer/src/lib/work-items/linked-work-item-context.test.ts": 64,
|
||||
"src/renderer/src/lib/editor/monaco/monaco-editor-gutter-disposal.test.ts": 295,
|
||||
"src/renderer/src/lib/monaco-languages/markdown-heading-outline.test.ts": 70,
|
||||
"src/renderer/src/lib/monaco-languages/monarch-embed-entry-recursion.test.ts": 697,
|
||||
@@ -6452,37 +6329,25 @@
|
||||
"src/renderer/src/lib/monaco-languages/textmate-token-provider.test.ts": 245,
|
||||
"src/renderer/src/lib/monaco-languages/zig-highlighting.test.ts": 7984,
|
||||
"src/renderer/src/lib/agent-session/resume/cli-fork/native-chat-cli-fork-preparation.test.ts": 2773,
|
||||
"src/renderer/src/lib/new-workspace.test.ts": 4534,
|
||||
"src/renderer/src/lib/non-secure-context-crypto.repro.test.ts": 1691,
|
||||
"src/renderer/src/lib/onboarding-folder-cancellation.test.ts": 2486,
|
||||
"src/renderer/src/lib/open-agent-message-sender.test.ts": 1497,
|
||||
"src/renderer/src/lib/simulator/launch/open-mobile-emulator-tab.test.ts": 545,
|
||||
"src/renderer/src/lib/orca-yaml-trust-prompt-slot-eviction.test.ts": 884,
|
||||
"src/renderer/src/lib/order-empty-query-worktrees.test.ts": 62,
|
||||
"src/renderer/src/lib/os-file-drop-cancellation-guard.test.ts": 204,
|
||||
"src/renderer/src/lib/os-file-drop-preload-integration.test.tsx": 353,
|
||||
"src/renderer/src/lib/files/drop/os-file-drop-cancellation-guard.test.ts": 204,
|
||||
"src/renderer/src/lib/paired-runtime-closed-tab-resume.test.ts": 2008,
|
||||
"src/renderer/src/lib/pane-manager/pane-close-focus-successor.test.ts": 1123,
|
||||
"src/renderer/src/lib/pane-manager/pane-container-listener-lifecycle.test.ts": 312,
|
||||
"src/renderer/src/lib/pane-manager/pane-cursor-blink-suspension.test.ts": 429,
|
||||
"src/renderer/src/lib/pane-manager/pane-drag-window-blur.test.ts": 618,
|
||||
"src/renderer/src/lib/pane-manager/pane-fit-resize-observer.test.ts": 94,
|
||||
"src/renderer/src/lib/pane-manager/pane-fit.test.ts": 166,
|
||||
"src/renderer/src/lib/pane-manager/pane-inline-image-recovery.test.ts": 61,
|
||||
"src/renderer/src/lib/pane-manager/pane-inline-images.test.ts": 74,
|
||||
"src/renderer/src/lib/pane-manager/pane-layout-geometry-apply.test.ts": 897,
|
||||
"src/renderer/src/lib/pane-manager/pane-manager-registry.test.ts": 69,
|
||||
"src/renderer/src/lib/pane-manager/pane-manager-spawn-placement.test.ts": 766,
|
||||
"src/renderer/src/lib/pane-manager/pane-overlay-focus.test.ts": 622,
|
||||
"src/renderer/src/lib/pane-manager/pane-scroll.test.ts": 153,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-foreground-render-settle.test.ts": 43,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-mouse-wheel.test.ts": 88,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-output-queue-chunks.test.ts": 44,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler-ack-credit.test.ts": 173,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler-disposed-writes.test.ts": 121,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler-queue-retention.test.ts": 301,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler-synchronized-frames.test.ts": 213,
|
||||
"src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler.test.ts": 236,
|
||||
"src/renderer/src/lib/pane-manager/pane-tree-equalization-parity.test.ts": 182,
|
||||
"src/renderer/src/lib/pane-manager/pane-tree-equalization-scaling.test.ts": 239,
|
||||
"src/renderer/src/lib/pane-manager/pane-tree-match-moves.test.ts": 662,
|
||||
@@ -6499,7 +6364,6 @@
|
||||
"src/renderer/src/lib/pane-manager/terminal-indic-cluster-ranges.test.ts": 50,
|
||||
"src/renderer/src/lib/pane-manager/terminal-kitty-file-reader.test.ts": 83,
|
||||
"src/renderer/src/lib/pane-manager/terminal-ligatures-addon.test.ts": 59,
|
||||
"src/renderer/src/lib/pane-manager/terminal-link-provider-guard.test.ts": 48,
|
||||
"src/renderer/src/lib/pane-manager/terminal-linkifier-hover-reset-on-write.test.ts": 59,
|
||||
"src/renderer/src/lib/pane-manager/terminal-mouse-encoding-tracker.test.ts": 95,
|
||||
"src/renderer/src/lib/pane-manager/terminal-mouse-report-finite-coordinates.test.ts": 272,
|
||||
@@ -6517,30 +6381,24 @@
|
||||
"src/renderer/src/lib/pane-manager/xterm-instance-disposed.test.ts": 57,
|
||||
"src/renderer/src/lib/pane-manager/xterm-parse-barrier.test.ts": 154,
|
||||
"src/renderer/src/lib/pane-manager/xterm-user-scrolling-contract.test.ts": 1266,
|
||||
"src/renderer/src/lib/pane-manager/xterm-write-callback-guard.test.ts": 53,
|
||||
"src/renderer/src/lib/pane-spawn-deferral-drain.test.ts": 61,
|
||||
"src/renderer/src/lib/parked-terminal-host-hydration.test.ts": 274,
|
||||
"src/renderer/src/lib/paste-payload-metadata.test.ts": 53,
|
||||
"src/renderer/src/lib/path-head-elision.test.ts": 53,
|
||||
"src/renderer/src/components/terminal-pane/session-restore/spawn-deferral/pane-spawn-deferral-drain.test.ts": 61,
|
||||
"src/renderer/src/components/terminal-pane/mounting/parked-terminal-host-hydration.test.ts": 274,
|
||||
"src/renderer/src/lib/text-input/paste/paste-payload-metadata.test.ts": 53,
|
||||
"src/renderer/src/lib/path-display/path-head-elision.test.ts": 53,
|
||||
"src/renderer/src/lib/path.test.ts": 55,
|
||||
"src/renderer/src/lib/plugin-command-keybindings.test.ts": 1909,
|
||||
"src/renderer/src/lib/plugin-command-replacements.test.ts": 95,
|
||||
"src/renderer/src/lib/plugin-icons/plugin-icon-svg.test.ts": 231,
|
||||
"src/renderer/src/lib/plugin-monaco-token-rules.test.ts": 51,
|
||||
"src/renderer/src/lib/pr-bot-author-overrides.test.ts": 349,
|
||||
"src/renderer/src/lib/editor/appearance/plugin-monaco-token-rules.test.ts": 51,
|
||||
"src/renderer/src/lib/source-control/review/pr-bot-author-overrides.test.ts": 349,
|
||||
"src/renderer/src/lib/source-control/review/comments/pr-comment-thread-resolution.test.ts": 48,
|
||||
"src/renderer/src/lib/project-clone-url-prefill.test.ts": 61,
|
||||
"src/renderer/src/lib/project-host-workspace-target.jira-mapping.test.ts": 76,
|
||||
"src/renderer/src/lib/project-host-workspace-target.test.ts": 92,
|
||||
"src/renderer/src/lib/react-commit-cascade-observer.react185.test.tsx": 285,
|
||||
"src/renderer/src/lib/react-commit-cascade-observer.test.ts": 189,
|
||||
"src/renderer/src/lib/react-commit-cascade-telemetry.test.ts": 159,
|
||||
"src/renderer/src/lib/react-error-boundary-reporting.test.ts": 55,
|
||||
"src/renderer/src/lib/workspace/creation/project-clone-url-prefill.test.ts": 61,
|
||||
"src/renderer/src/lib/workspace/creation/project-host-workspace-target.jira-mapping.test.ts": 76,
|
||||
"src/renderer/src/lib/workspace/creation/project-host-workspace-target.test.ts": 92,
|
||||
"src/renderer/src/lib/editor/file-operations/remap-open-editor-tabs-for-path-change.test.ts": 2178,
|
||||
"src/renderer/src/lib/rename-user-named-tab-access.test.ts": 2804,
|
||||
"src/renderer/src/lib/renderer-agent-status-observation-ingress.test.ts": 81,
|
||||
"src/renderer/src/lib/renderer-app-platform.test.ts": 197,
|
||||
"src/renderer/src/lib/renderer-memory-profile.test.ts": 70,
|
||||
"src/renderer/src/diagnostics/memory/renderer-memory-profile.test.ts": 70,
|
||||
"src/renderer/src/lib/repo-search.test.ts": 54,
|
||||
"src/renderer/src/lib/repo-slug-cache.test.ts": 52,
|
||||
"src/renderer/src/lib/repo-slug-index.test.ts": 2240,
|
||||
@@ -6563,7 +6421,6 @@
|
||||
"src/renderer/src/lib/script-textarea-rows.test.ts": 93,
|
||||
"src/renderer/src/lib/session-write-subscriber-acknowledgment.test.ts": 1823,
|
||||
"src/renderer/src/lib/session-write-subscriber.test.ts": 1882,
|
||||
"src/renderer/src/lib/shutdown-checkpoint-guard.test.ts": 209,
|
||||
"src/renderer/src/lib/sidebar-ended-creations.test.ts": 1889,
|
||||
"src/renderer/src/lib/sidebar-pending-layer.test.ts": 338,
|
||||
"src/renderer/src/lib/sidebar-shadow/workspace-activity-shadow.test.ts": 1728,
|
||||
@@ -6572,10 +6429,9 @@
|
||||
"src/renderer/src/lib/simulator/tabs/simulator-pane-shutdown-scheduler.test.ts": 1679,
|
||||
"src/renderer/src/lib/simulator/tabs/simulator-tab-layout-owner.test.ts": 2398,
|
||||
"src/renderer/src/lib/simulator/tabs/simulator-tab-palette-activation.test.ts": 1903,
|
||||
"src/renderer/src/lib/sleeping-agent-session-launch-windows-quoting.test.ts": 547,
|
||||
"src/renderer/src/lib/source-control/remote/source-control-remote-error.test.ts": 340,
|
||||
"src/renderer/src/lib/ssh-config-passive-sync.test.ts": 1513,
|
||||
"src/renderer/src/lib/state-collection-byte-estimate.test.ts": 86,
|
||||
"src/renderer/src/diagnostics/memory/state-collection-byte-estimate.test.ts": 86,
|
||||
"src/renderer/src/lib/agent-session/launch/structured-agent-session-launch-draft.test.ts": 1042,
|
||||
"src/renderer/src/lib/agent-session/launch/structured-agent-session-launch-prerequisites.test.ts": 2427,
|
||||
"src/renderer/src/lib/agent-session/options/structured-agent-session-selection-lifetime.test.tsx": 2947,
|
||||
@@ -6587,10 +6443,10 @@
|
||||
"src/renderer/src/lib/syntax-highlighting/textmate-core.test.ts": 60,
|
||||
"src/renderer/src/lib/tab-agent-status-index.test.ts": 210,
|
||||
"src/renderer/src/lib/task-provider-error-copy.test.ts": 363,
|
||||
"src/renderer/src/lib/terminal-app-theme.test.ts": 301,
|
||||
"src/renderer/src/app-shell/appearance/terminal-app-theme.test.ts": 301,
|
||||
"src/renderer/src/lib/terminal-input-activity-coalescing.test.ts": 43,
|
||||
"src/renderer/src/lib/text-control-paste-ownership.test.ts": 217,
|
||||
"src/renderer/src/lib/text-control-paste.test.ts": 222,
|
||||
"src/renderer/src/lib/text-input/paste/text-control-paste-ownership.test.ts": 217,
|
||||
"src/renderer/src/lib/text-input/paste/text-control-paste.test.ts": 222,
|
||||
"src/renderer/src/lib/text-generation-error-copy.test.ts": 466,
|
||||
"src/renderer/src/lib/typing-latency/echo-instrumentation.test.ts": 145,
|
||||
"src/renderer/src/lib/typing-latency/renderer-long-tasks.test.ts": 75,
|
||||
@@ -6599,17 +6455,10 @@
|
||||
"src/renderer/src/lib/use-tab-agent-observed-signal-dispatch.test.tsx": 1971,
|
||||
"src/renderer/src/lib/use-tab-agent-opencode-native-title.test.ts": 2093,
|
||||
"src/renderer/src/lib/use-tab-agent.test.ts": 1961,
|
||||
"src/renderer/src/lib/user-opened-local-path.test.ts": 325,
|
||||
"src/renderer/src/lib/wake-sleeping-agents-live-unmounted-pane.test.ts": 2432,
|
||||
"src/renderer/src/lib/window-visibility-interval.test.ts": 48,
|
||||
"src/renderer/src/lib/window-visibility-timeout-poller.test.ts": 207,
|
||||
"src/renderer/src/lib/windows-terminal-capabilities-race.test.ts": 450,
|
||||
"src/renderer/src/lib/windows-terminal-capabilities.test.ts": 585,
|
||||
"src/renderer/src/lib/windows-terminal-capability-reprobe.test.ts": 198,
|
||||
"src/renderer/src/runtime/hosts/capabilities/windows-terminal-capabilities-race.test.ts": 450,
|
||||
"src/renderer/src/lib/workspace/activation/workspace-activation-path-gate.test.ts": 2107,
|
||||
"src/renderer/src/lib/browser/workspace/workspace-browser-tab-open-placement.test.ts": 1996,
|
||||
"src/renderer/src/lib/workspace-doc-address-input.test.ts": 470,
|
||||
"src/renderer/src/lib/workspace-file-drag.test.ts": 70,
|
||||
"src/renderer/src/lib/workspace-ports/workspace-port-scan-debounce.test.ts": 57,
|
||||
"src/renderer/src/lib/workspace/persistence/workspace-session-host-contention.test.ts": 265,
|
||||
"src/renderer/src/lib/workspace/persistence/workspace-session-host-emptied-fields.test.ts": 279,
|
||||
@@ -6699,7 +6548,6 @@
|
||||
"src/renderer/src/runtime/workspace-layout/server/server-layout-frames.test.ts": 2053,
|
||||
"src/renderer/src/runtime/native-chat/status/structured-agent-session-status-feed-lifecycle.test.ts": 62,
|
||||
"src/renderer/src/runtime/native-chat/status/structured-agent-session-status-feed.test.ts": 82,
|
||||
"src/renderer/src/runtime/native-chat/tab-retirement/structured-agent-session-tab-retirement.test.ts": 2115,
|
||||
"src/renderer/src/runtime/native-chat/status/structured-agent-session-turn-completion-feed.test.ts": 118,
|
||||
"src/renderer/src/runtime/native-chat/host-capabilities/structured-chat-host-permission.test.ts": 523,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/placement/structured-conversation-tab-replacement.test.ts": 2029,
|
||||
@@ -6716,11 +6564,6 @@
|
||||
"src/renderer/src/runtime/browser/creation/web-runtime-browser-creation-placement.test.ts": 1927,
|
||||
"src/renderer/src/runtime/browser/creation/web-runtime-browser-link-open.test.ts": 2217,
|
||||
"src/renderer/src/runtime/browser/creation/web-runtime-browser-link-session.test.ts": 1964,
|
||||
"src/renderer/src/runtime/browser/creation/web-runtime-session-browser-create-split-placement.test.ts": 949,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/closing/web-runtime-session-tab-activate-close.test.ts": 1426,
|
||||
"src/renderer/src/runtime/hosted-terminals/actions/web-runtime-session-terminal-pane-delegation.test.ts": 1341,
|
||||
"src/renderer/src/runtime/hosted-terminals/creation/web-runtime-session-terminal-workspace-routing.test.ts": 768,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/inventory/web-runtime-session.test.ts": 743,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/closing/web-session-close-replay.test.ts": 1119,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/placement/web-session-open-files-batch-equivalence.test.ts": 1478,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/identity/web-session-restored-placeholder-identity.test.ts": 985,
|
||||
@@ -6729,7 +6572,6 @@
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/subscriptions/web-session-tabs-stream-end-resubscribe.test.tsx": 2282,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/agent-status/web-session-tabs-sync-agent-status.test.ts": 987,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/placement/web-session-tabs-sync-browser-tabs.test.ts": 925,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/subscriptions/web-session-tabs-sync-completion-on-reveal.test.tsx": 2249,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/identity/web-session-tabs-sync-cross-runtime-worktree.test.ts": 964,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/placement/web-session-tabs-sync-editor-ownership.test.ts": 1902,
|
||||
"src/renderer/src/runtime/web-session-tabs-sync/placement/web-session-tabs-sync-editor-tabs.test.ts": 1073,
|
||||
@@ -6823,7 +6665,6 @@
|
||||
"src/renderer/src/store/slices/browser/pages/browser-workspace-doc-location.test.ts": 2007,
|
||||
"src/renderer/src/store/slices/browser/browser.test.ts": 2001,
|
||||
"src/renderer/src/store/slices/worktrees/teardown/bulk-worktree-purge-terminal-maps-leak.test.ts": 1727,
|
||||
"src/renderer/src/store/workspaces/creation/active-workspace-create-actions.test.ts": 1879,
|
||||
"src/renderer/src/store/terminals/codex-restart-notice-lifecycle.test.ts": 1685,
|
||||
"src/renderer/src/store/slices/tabs/content-tabs-from-main-frames.test.ts": 2025,
|
||||
"src/renderer/src/store/slices/tabs/content-tabs-paired-server-workspace.test.ts": 1923,
|
||||
@@ -6846,7 +6687,6 @@
|
||||
"src/renderer/src/store/slices/editor/git/editor-git-status-reconciliation.test.ts": 870,
|
||||
"src/renderer/src/store/slices/editor/tabs/editor-layout-owner-records.test.ts": 2006,
|
||||
"src/renderer/src/store/slices/editor/markdown/editor-markdown-link-activation.test.ts": 953,
|
||||
"src/renderer/src/store/slices/editor/markdown/editor-markdown-view-state.test.ts": 801,
|
||||
"src/renderer/src/store/slices/editor/git/editor-open-diff.test.ts": 1987,
|
||||
"src/renderer/src/store/slices/editor/tabs/editor-open-link-placement.test.ts": 1987,
|
||||
"src/renderer/src/store/slices/editor/tabs/editor-preview-tab-setting.test.ts": 1952,
|
||||
@@ -8015,7 +7855,7 @@
|
||||
"tests/e2e/ai-vault-account-stream.unit.test.ts": 4506,
|
||||
"tests/e2e/ai-vault-manual-name-clear.unit.test.ts": 21206,
|
||||
"tests/e2e/automation-chat-reopen.unit.test.ts": 6262,
|
||||
"tests/e2e/automation-save-fallback.unit.test.ts": 9065,
|
||||
|
||||
"tests/e2e/claude-agent-row-view.unit.test.ts": 1491,
|
||||
"tests/e2e/codex-child-approval-activity-row.unit.test.ts": 14886,
|
||||
"tests/e2e/completed-worker-retirement-resume.unit.test.ts": 38857,
|
||||
@@ -8051,7 +7891,7 @@
|
||||
"tests/e2e/host-agent-launch-preferences-work.unit.test.ts": 3882,
|
||||
"tests/e2e/host-agent-launch-settings-hook-bookkeeping.unit.test.ts": 21972,
|
||||
"tests/e2e/host-cold-park-remote-subscriber.unit.test.ts": 5314,
|
||||
"tests/e2e/journal-restored-consumers.unit.test.ts": 33933,
|
||||
|
||||
"tests/e2e/launch-agent-background-session-remote.unit.test.ts": 1016,
|
||||
"tests/e2e/launch-agent-in-new-tab-web-runtime.unit.test.ts": 14288,
|
||||
"tests/e2e/linear-cli-recovery.unit.test.ts": 7592,
|
||||
@@ -8063,7 +7903,7 @@
|
||||
"tests/e2e/native-chat-rewind-boundary.unit.test.ts": 2977,
|
||||
"tests/e2e/native-chat-ssh-transcript.unit.test.ts": 1166,
|
||||
"tests/e2e/native-chat-startup-option-pickers.unit.test.ts": 9377,
|
||||
"tests/e2e/native-chat-transcript-file-order.unit.test.ts": 1066,
|
||||
|
||||
"tests/e2e/native-chat-transcript-reasoning.unit.test.ts": 3341,
|
||||
"tests/e2e/nested-agent-idle-owner.unit.test.ts": 2469,
|
||||
"tests/e2e/omp-child-session-recovery.unit.test.ts": 2205,
|
||||
@@ -8098,12 +7938,9 @@
|
||||
"tests/e2e/structured-session-tab-close-regressions.unit.test.ts": 32432,
|
||||
"tests/e2e/sustained-agent-typing-load-scripts.unit.test.ts": 2169,
|
||||
"tests/e2e/task-page-linear-refresh-authority.unit.test.ts": 5548,
|
||||
"tests/e2e/task-page-linear-refresh-transport.unit.test.ts": 2019,
|
||||
"tests/e2e/terminal-agent-fork-draft-ownership.unit.test.ts": 30195,
|
||||
"tests/e2e/terminal-binding-crash-hydration.unit.test.ts": 1769,
|
||||
"tests/e2e/terminal-foreground-confirmation.unit.test.ts": 644,
|
||||
"tests/e2e/terminal-perf-presentation.unit.test.ts": 60,
|
||||
"tests/e2e/web-runtime-session-terminal-host-authority.unit.test.ts": 1061,
|
||||
"tests/e2e/worktree-status-warning.unit.test.ts": 2331,
|
||||
"tests/tools/branch-line-total-renderer.test.mjs": 1222,
|
||||
"tests/tools/omp-close-lifecycle.test.mjs": 403,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
const { createHash } = require('node:crypto')
|
||||
const { readFileSync, readdirSync, statSync } = require('node:fs')
|
||||
const { join, resolve } = require('node:path')
|
||||
const { brotliDecompressSync } = require('node:zlib')
|
||||
|
||||
const { darkBuildMarkerFileNames } = require('../../../dark-build-switches.cjs')
|
||||
|
||||
@@ -98,6 +99,25 @@ function parseManifest(bundleDir) {
|
||||
if (typeof asset.contentType !== 'string' || asset.contentType.length === 0) {
|
||||
throw failure(`manifest asset ${asset.path} has no contentType`)
|
||||
}
|
||||
if (asset.brotliByteLength !== undefined) {
|
||||
assertInteger(asset.brotliByteLength, `assets[${asset.path}].brotliByteLength`)
|
||||
if (asset.brotliByteLength >= asset.byteLength) {
|
||||
throw failure(`manifest asset ${asset.path} declares a brotli copy no smaller than itself`)
|
||||
}
|
||||
}
|
||||
}
|
||||
if (manifest.catalogs !== undefined && !Array.isArray(manifest.catalogs)) {
|
||||
throw failure('manifest catalogs is not a list')
|
||||
}
|
||||
for (const catalog of manifest.catalogs ?? []) {
|
||||
if (typeof catalog !== 'object' || catalog === null || typeof catalog.locale !== 'string') {
|
||||
throw failure('manifest catalog entry has no locale')
|
||||
}
|
||||
assertSafeRelativePath(catalog.path)
|
||||
if (typeof catalog.sha256 !== 'string' || !SHA256_PATTERN.test(catalog.sha256)) {
|
||||
throw failure(`manifest catalog ${catalog.path} has no sha256 digest`)
|
||||
}
|
||||
assertInteger(catalog.byteLength, `catalogs[${catalog.path}].byteLength`)
|
||||
}
|
||||
if (!manifest.assets.some((asset) => asset.path === manifest.entrypoint)) {
|
||||
throw failure(`manifest entrypoint ${manifest.entrypoint} is not one of its assets`)
|
||||
@@ -119,6 +139,11 @@ function parseManifest(bundleDir) {
|
||||
return manifest
|
||||
}
|
||||
|
||||
// Assets go to the phone; catalogs stay on the host, which serves one on request.
|
||||
function servedFiles(manifest) {
|
||||
return [...manifest.assets, ...(manifest.catalogs ?? [])]
|
||||
}
|
||||
|
||||
function listBundleFiles(directory, prefix = '') {
|
||||
const found = []
|
||||
for (const entry of readdirSync(directory, { withFileTypes: true })) {
|
||||
@@ -132,13 +157,33 @@ function listBundleFiles(directory, prefix = '') {
|
||||
return found
|
||||
}
|
||||
|
||||
// Mirrors mobileWebBundleBrotliPath in src/shared/mobile-web-bundle/manifest-contract.ts.
|
||||
function brotliPath(asset) {
|
||||
return `${asset.path}.br`
|
||||
}
|
||||
|
||||
function brotliCopies(manifest) {
|
||||
return manifest.assets.filter((asset) => asset.brotliByteLength !== undefined)
|
||||
}
|
||||
|
||||
function statSize(bundleDir, path) {
|
||||
try {
|
||||
return statSync(join(bundleDir, path)).size
|
||||
} catch (error) {
|
||||
throw failure(
|
||||
`manifest lists ${path}, which is missing from ${bundleDir} (${error.code ?? error.message}). ${REMEDY}`
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
// Reject unlisted on-disk assets: content-addressed stale files survive interrupted builds and would ship unreachable/unverified in asar.
|
||||
function assertNoUnlistedFiles(bundleDir, manifest) {
|
||||
// A dark build's marker is accounted for here; packaging refuses it through assertNotDarkBuild.
|
||||
const listed = new Set([
|
||||
'manifest.json',
|
||||
...darkBuildMarkerFileNames(),
|
||||
...manifest.assets.map((asset) => asset.path)
|
||||
...servedFiles(manifest).map((file) => file.path),
|
||||
...brotliCopies(manifest).map((asset) => brotliPath(asset))
|
||||
])
|
||||
const strays = listBundleFiles(bundleDir).filter((path) => !listed.has(path))
|
||||
if (strays.length > 0) {
|
||||
@@ -153,16 +198,9 @@ function assertNoUnlistedFiles(bundleDir, manifest) {
|
||||
function assertMobileWebBundleBuilt(bundleDir = MOBILE_WEB_BUNDLE_DIR) {
|
||||
const manifest = parseManifest(bundleDir)
|
||||
assertNoUnlistedFiles(bundleDir, manifest)
|
||||
for (const asset of manifest.assets) {
|
||||
for (const asset of servedFiles(manifest)) {
|
||||
const assetPath = join(bundleDir, asset.path)
|
||||
let size
|
||||
try {
|
||||
size = statSync(assetPath).size
|
||||
} catch (error) {
|
||||
throw failure(
|
||||
`manifest lists ${asset.path}, which is missing from ${bundleDir} (${error.code ?? error.message}). ${REMEDY}`
|
||||
)
|
||||
}
|
||||
const size = statSize(bundleDir, asset.path)
|
||||
if (size !== asset.byteLength) {
|
||||
throw failure(
|
||||
`${asset.path} is ${String(size)} bytes on disk, manifest says ${String(asset.byteLength)}. ${REMEDY}`
|
||||
@@ -175,6 +213,20 @@ function assertMobileWebBundleBuilt(bundleDir = MOBILE_WEB_BUNDLE_DIR) {
|
||||
)
|
||||
}
|
||||
}
|
||||
// Phones verify only the inflated bytes, so a copy that inflates to anything else fails every download.
|
||||
for (const asset of brotliCopies(manifest)) {
|
||||
const path = brotliPath(asset)
|
||||
const size = statSize(bundleDir, path)
|
||||
if (size !== asset.brotliByteLength) {
|
||||
throw failure(
|
||||
`${path} is ${String(size)} bytes on disk, manifest says ${String(asset.brotliByteLength)}. ${REMEDY}`
|
||||
)
|
||||
}
|
||||
const inflated = brotliDecompressSync(readFileSync(join(bundleDir, path)))
|
||||
if (createHash('sha256').update(inflated).digest('hex') !== asset.sha256) {
|
||||
throw failure(`${path} does not inflate to ${asset.path}. ${REMEDY}`)
|
||||
}
|
||||
}
|
||||
console.log(
|
||||
`[verify-packaged-mobile-web-bundle] OK — buildId ${manifest.buildId}, ` +
|
||||
`${String(manifest.assets.length)} asset(s), ${String(manifest.totalBytes)} bytes`
|
||||
|
||||
@@ -2,6 +2,7 @@ import { mkdtemp, readFile, rm, writeFile } from 'node:fs/promises'
|
||||
import { createRequire } from 'node:module'
|
||||
import { tmpdir } from 'node:os'
|
||||
import { join } from 'node:path'
|
||||
import { brotliCompressSync } from 'node:zlib'
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import { writeMobileWebBundleFixtureTree } from '../../build/mobile-web-app/mobile-web-bundle-fixture-tree.mjs'
|
||||
|
||||
@@ -10,11 +11,11 @@ const { assertMobileWebBundleBuilt } = require('./verify-packaged-mobile-web-bun
|
||||
const electronBuilderConfig = require('../../../electron-builder.config.cjs')
|
||||
const { darkBuildMarkers } = require('../../../dark-build-switches.cjs')
|
||||
|
||||
async function withBundle(run) {
|
||||
async function withBundle(run, { brotli = false } = {}) {
|
||||
const scratch = await mkdtemp(join(tmpdir(), 'orca-mobile-web-guard-'))
|
||||
const bundleDir = join(scratch, 'mobile-web')
|
||||
try {
|
||||
const { manifest } = await writeMobileWebBundleFixtureTree({ outDir: bundleDir })
|
||||
const { manifest } = await writeMobileWebBundleFixtureTree({ outDir: bundleDir, brotli })
|
||||
await run({ bundleDir, manifest })
|
||||
} finally {
|
||||
await rm(scratch, { recursive: true, force: true })
|
||||
@@ -65,6 +66,25 @@ describe('assertMobileWebBundleBuilt', () => {
|
||||
})
|
||||
})
|
||||
|
||||
it('accepts the brotli copies the manifest lists, and fails one that inflates to other bytes', async () => {
|
||||
await withBundle(
|
||||
async ({ bundleDir, manifest }) => {
|
||||
const asset = manifest.assets.find((entry) => entry.brotliByteLength !== undefined)
|
||||
expect(() => assertMobileWebBundleBuilt(bundleDir)).not.toThrow()
|
||||
const forged = brotliCompressSync(Buffer.from('not the asset'))
|
||||
await writeFile(join(bundleDir, `${asset.path}.br`), forged)
|
||||
await rewriteManifest(bundleDir, (rewritten) => {
|
||||
rewritten.assets.find((entry) => entry.path === asset.path).brotliByteLength =
|
||||
forged.byteLength
|
||||
})
|
||||
expect(() => assertMobileWebBundleBuilt(bundleDir)).toThrow(
|
||||
`${asset.path}.br does not inflate to ${asset.path}`
|
||||
)
|
||||
},
|
||||
{ brotli: true }
|
||||
)
|
||||
})
|
||||
|
||||
it('refuses an asset path that escapes the bundle directory', async () => {
|
||||
await withBundle(async ({ bundleDir }) => {
|
||||
await rewriteManifest(bundleDir, (manifest) => {
|
||||
|
||||
@@ -6,10 +6,11 @@ import process from 'node:process'
|
||||
// TypeScript 7 is a native CLI; AST consumers still need the legacy JavaScript API.
|
||||
import ts from 'typescript-api'
|
||||
import { isTestOnlySourcePath } from '../../static-analysis/process-boundaries/test-only-source-path.mjs'
|
||||
import { isVisibleObjectKey } from './localization-visible-object-keys.mjs'
|
||||
|
||||
const SOURCE_EXTENSIONS = new Set(['.ts', '.tsx', '.js', '.jsx', '.mts', '.cts'])
|
||||
const SKIP_PATH_PARTS = new Set(['.git', 'dist', 'node_modules', 'out', '__snapshots__', 'assets'])
|
||||
const LOCALIZATION_CALL_NAMES = new Set(['t', 'translate'])
|
||||
const LOCALIZATION_CALL_NAMES = new Set(['t', 'translate', 'translateMain'])
|
||||
const CLASS_PROPERTY_NAMES = new Set(['className', 'classNames'])
|
||||
// Why: the children of these elements are CSS or code, never copy a translator should see.
|
||||
const NON_COPY_JSX_ELEMENTS = new Set(['style', 'script'])
|
||||
@@ -35,25 +36,6 @@ const USER_VISIBLE_JSX_ATTRIBUTES = new Set([
|
||||
'toggleDescription',
|
||||
'tooltip'
|
||||
])
|
||||
const USER_VISIBLE_OBJECT_KEYS = new Set([
|
||||
'accessibilityHint',
|
||||
'accessibilityLabel',
|
||||
'ariaLabel',
|
||||
'badge',
|
||||
'description',
|
||||
'emptyText',
|
||||
'error',
|
||||
'headerTitle',
|
||||
'helperText',
|
||||
'keywords',
|
||||
'label',
|
||||
'message',
|
||||
'placeholder',
|
||||
'subtitle',
|
||||
'title',
|
||||
'toggleDescription',
|
||||
'tooltip'
|
||||
])
|
||||
const USER_VISIBLE_FUNCTION_NAMES = new Set([
|
||||
'alert',
|
||||
'confirm',
|
||||
@@ -331,7 +313,7 @@ function isInsideNonCopyJsxElement(node) {
|
||||
return Boolean(element && NON_COPY_JSX_ELEMENTS.has(element.openingElement.tagName.getText()))
|
||||
}
|
||||
|
||||
function classifyStringNode(node) {
|
||||
function classifyStringNode(node, includeNativeDialogFields = false) {
|
||||
if (
|
||||
hasAncestorObjectPropertyName(node, CLASS_PROPERTY_NAMES) ||
|
||||
isInsideNonCopyJsxElement(node)
|
||||
@@ -369,12 +351,15 @@ function classifyStringNode(node) {
|
||||
}
|
||||
|
||||
const objectPropertyName = nearestObjectPropertyName(node)
|
||||
if (objectPropertyName && !USER_VISIBLE_OBJECT_KEYS.has(objectPropertyName)) {
|
||||
if (objectPropertyName && !isVisibleObjectKey(objectPropertyName, includeNativeDialogFields)) {
|
||||
return undefined
|
||||
}
|
||||
|
||||
const ancestorObjectPropertyName = nearestAncestorObjectPropertyName(node)
|
||||
if (ancestorObjectPropertyName && !USER_VISIBLE_OBJECT_KEYS.has(ancestorObjectPropertyName)) {
|
||||
if (
|
||||
ancestorObjectPropertyName &&
|
||||
!isVisibleObjectKey(ancestorObjectPropertyName, includeNativeDialogFields)
|
||||
) {
|
||||
return undefined
|
||||
}
|
||||
|
||||
@@ -407,7 +392,12 @@ function areaForFile(relativePath) {
|
||||
return `renderer/${parts[0] ?? 'root'}`
|
||||
}
|
||||
|
||||
export function collectLocalizationCandidates(filePath, sourceText, root = process.cwd()) {
|
||||
export function collectLocalizationCandidates(
|
||||
filePath,
|
||||
sourceText,
|
||||
root = process.cwd(),
|
||||
options = {}
|
||||
) {
|
||||
const sourceKind =
|
||||
filePath.endsWith('.tsx') || filePath.endsWith('.jsx') ? ts.ScriptKind.TSX : ts.ScriptKind.TS
|
||||
const sourceFile = ts.createSourceFile(
|
||||
@@ -450,7 +440,7 @@ export function collectLocalizationCandidates(filePath, sourceText, root = proce
|
||||
ts.isNoSubstitutionTemplateLiteral(node) ||
|
||||
ts.isTemplateExpression(node)
|
||||
) {
|
||||
const kind = classifyStringNode(node)
|
||||
const kind = classifyStringNode(node, options.includeNativeDialogFields)
|
||||
if (kind) {
|
||||
for (const part of stringParts(node)) {
|
||||
pushReport(node, kind, part.text, part.dynamic)
|
||||
@@ -521,6 +511,7 @@ function parseArgs(argv) {
|
||||
allowlistPath: path.join('config', 'localization-coverage-allowlist.json'),
|
||||
check: false,
|
||||
format: 'summary',
|
||||
includeNativeDialogFields: false,
|
||||
outputPath: null,
|
||||
sourceRoots: []
|
||||
}
|
||||
@@ -531,6 +522,8 @@ function parseArgs(argv) {
|
||||
options.format = 'json'
|
||||
} else if (arg === '--markdown') {
|
||||
options.format = 'markdown'
|
||||
} else if (arg === '--native-dialog-fields') {
|
||||
options.includeNativeDialogFields = true
|
||||
} else if (arg === '--check') {
|
||||
options.check = true
|
||||
} else if (arg === '--allowlist') {
|
||||
@@ -616,7 +609,7 @@ export async function main(root = process.cwd(), argv = process.argv.slice(2)) {
|
||||
|
||||
for (const filePath of files) {
|
||||
const sourceText = await fs.readFile(filePath, 'utf8')
|
||||
reports.push(...collectLocalizationCandidates(filePath, sourceText, root))
|
||||
reports.push(...collectLocalizationCandidates(filePath, sourceText, root, options))
|
||||
}
|
||||
|
||||
if (options.check) {
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
import { describe, expect, it, vi } from 'vitest'
|
||||
import { mkdtemp, mkdir, rm, writeFile } from 'node:fs/promises'
|
||||
import { tmpdir } from 'node:os'
|
||||
import { join } from 'node:path'
|
||||
import { collectLocalizationCandidates, main } from './audit-localization-coverage.mjs'
|
||||
|
||||
const path = '/repo/src/main/startup/dialog.ts'
|
||||
const source = `
|
||||
const options = {
|
||||
message: translateMain('message', 'Translated message'),
|
||||
detail: 'Untranslated detail',
|
||||
buttons: ['Proceed', translateMain('cancel', 'Cancel')],
|
||||
body: 'Untranslated body',
|
||||
buttonLabel: 'Retry',
|
||||
checkboxLabel: 'Remember choice'
|
||||
}
|
||||
`
|
||||
|
||||
describe('native dialog localization coverage', () => {
|
||||
it('finds untranslated native dialog fields while ignoring translated copy', () => {
|
||||
const candidates = collectLocalizationCandidates(path, source, '/repo', {
|
||||
includeNativeDialogFields: true
|
||||
})
|
||||
expect(candidates.map(({ kind, text }) => [kind, text])).toEqual([
|
||||
['object-property:detail', 'Untranslated detail'],
|
||||
['object-property:buttons', 'Proceed'],
|
||||
['object-property:body', 'Untranslated body'],
|
||||
['object-property:buttonLabel', 'Retry'],
|
||||
['object-property:checkboxLabel', 'Remember choice']
|
||||
])
|
||||
})
|
||||
|
||||
it('does not change the existing renderer scan by default', () => {
|
||||
expect(collectLocalizationCandidates(path, source, '/repo')).toEqual([])
|
||||
})
|
||||
|
||||
it('fails the opt-in check for a new native dialog literal', async () => {
|
||||
const root = await mkdtemp(join(tmpdir(), 'orca-native-localization-'))
|
||||
const report = vi.spyOn(console, 'error').mockImplementation(() => {})
|
||||
try {
|
||||
await mkdir(join(root, 'src'))
|
||||
await writeFile(join(root, 'src', 'dialog.ts'), "const options = { detail: 'Raw detail' }")
|
||||
await writeFile(join(root, 'allowlist.json'), '[]')
|
||||
await expect(
|
||||
main(root, [
|
||||
'--check',
|
||||
'--native-dialog-fields',
|
||||
'--source-root',
|
||||
'src',
|
||||
'--allowlist',
|
||||
'allowlist.json'
|
||||
])
|
||||
).resolves.toBe(1)
|
||||
} finally {
|
||||
report.mockRestore()
|
||||
await rm(root, { recursive: true, force: true })
|
||||
}
|
||||
})
|
||||
})
|
||||
@@ -0,0 +1,33 @@
|
||||
const USER_VISIBLE_OBJECT_KEYS = new Set([
|
||||
'accessibilityHint',
|
||||
'accessibilityLabel',
|
||||
'ariaLabel',
|
||||
'badge',
|
||||
'description',
|
||||
'emptyText',
|
||||
'error',
|
||||
'headerTitle',
|
||||
'helperText',
|
||||
'keywords',
|
||||
'label',
|
||||
'message',
|
||||
'placeholder',
|
||||
'subtitle',
|
||||
'title',
|
||||
'toggleDescription',
|
||||
'tooltip'
|
||||
])
|
||||
const NATIVE_DIALOG_OBJECT_KEYS = new Set([
|
||||
'detail',
|
||||
'buttons',
|
||||
'body',
|
||||
'buttonLabel',
|
||||
'checkboxLabel'
|
||||
])
|
||||
|
||||
export function isVisibleObjectKey(name, includeNativeDialogFields) {
|
||||
return (
|
||||
USER_VISIBLE_OBJECT_KEYS.has(name) ||
|
||||
(includeNativeDialogFields && NATIVE_DIALOG_OBJECT_KEYS.has(name))
|
||||
)
|
||||
}
|
||||
@@ -32,7 +32,7 @@ import { View } from 'react-native'
|
||||
import { GestureHandlerRootView } from 'react-native-gesture-handler'
|
||||
import { MobileNativeChatQueuedMessages } from './src/session/native-chat/input/MobileNativeChatQueuedMessages'
|
||||
import { MobileNativeChatComposer } from './src/session/native-chat/composer/MobileNativeChatComposer'
|
||||
import { mobileQueuedMessageCards } from './src/session/mobile-structured-queued-message-cards'
|
||||
import { mobileQueuedMessageCards } from './src/session/native-chat/input/mobile-structured-queued-message-cards'
|
||||
import { activateMobileUiLocale, translate } from './src/i18n/mobile-i18n'
|
||||
|
||||
const [mode, locale] = location.hash.slice(1).split(':')
|
||||
|
||||
@@ -19,7 +19,7 @@ export function stageOrcadMobileWebBundle(outputDir, bundleDir = MOBILE_WEB_BUND
|
||||
// The release template refuses the variable itself.
|
||||
assertNoDarkOutputOfOffSwitches([bundleDir])
|
||||
assertMobileWebBundleBuilt(bundleDir)
|
||||
// The guard refuses unlisted files, so the tree is the manifest, its assets and a dark marker.
|
||||
// The guard refuses unlisted files, so the tree is the manifest, its assets and catalogs, and a dark marker.
|
||||
cpSync(bundleDir, join(outputDir, ...ORCAD_MOBILE_WEB_DIR.split('/')), { recursive: true })
|
||||
}
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ const { sortJiraIssues } = await jiti.import(
|
||||
'../../../../src/renderer/src/components/jira-issue-sorter.ts'
|
||||
)
|
||||
const { sortAutomationListViewItems } = await jiti.import(
|
||||
'../../../../src/renderer/src/components/automations/automation-list-view.ts'
|
||||
'../../../../src/renderer/src/components/automations/listing/automation-list-view.ts'
|
||||
)
|
||||
const automationLocale = 'en-US'
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ import { performance } from 'node:perf_hooks'
|
||||
import { transform } from 'esbuild'
|
||||
import { buildCounterbalancedSchedule } from '../measurement/counterbalanced-benchmark-schedule.mjs'
|
||||
|
||||
const path = 'src/renderer/src/components/skills/skill-source-inventory.ts'
|
||||
const path = 'src/renderer/src/components/skills/catalog/skill-source-inventory.ts'
|
||||
const arms = {}
|
||||
for (const [name, source] of [
|
||||
['baseline', readFileSync(0, 'utf8')],
|
||||
|
||||
@@ -47,6 +47,8 @@ const RATCHET_INPUTS = {
|
||||
'check-render-path-translate-ratchet.mjs': ['src/renderer/src/'],
|
||||
'check-repo-host-read-ratchet.mjs': ['src/cli/', 'src/main/', 'src/shared/'],
|
||||
'check-runtime-electron-ratchet.mjs': ['src/main/', 'src/cli/', 'src/shared/'],
|
||||
'check-tab-map-seam-ratchet.mjs': ['src/renderer/src/'],
|
||||
'check-terminal-parking-ownership-ratchet.mjs': ['src/renderer/src/'],
|
||||
'check-unproven-pty-retirement-ratchet.mjs': ['src/main/'],
|
||||
'check-workspace-record-read-ratchet.mjs': ['src/renderer/src/'],
|
||||
'check-worktree-id-composer-ratchet.mjs': ['src/', 'mobile/src/']
|
||||
@@ -101,7 +103,33 @@ export const VERIFY_CHECKS = [
|
||||
'config/scripts/localization/source-extraction/audit-localization-coverage.mjs',
|
||||
'--check'
|
||||
],
|
||||
inputs: ['src/renderer/src/', LOCALES]
|
||||
inputs: [
|
||||
'src/renderer/src/',
|
||||
LOCALES,
|
||||
'config/scripts/localization/source-extraction/audit-localization-coverage',
|
||||
'config/scripts/localization/source-extraction/localization-visible-object-keys'
|
||||
]
|
||||
},
|
||||
{
|
||||
name: 'startup and worktree localization coverage',
|
||||
args: [
|
||||
'config/scripts/localization/source-extraction/audit-localization-coverage.mjs',
|
||||
'--check',
|
||||
'--native-dialog-fields',
|
||||
'--source-root',
|
||||
'src/main/startup',
|
||||
'--source-root',
|
||||
'src/shared/worktree',
|
||||
'--allowlist',
|
||||
'config/startup-worktree-localization-allowlist.json'
|
||||
],
|
||||
inputs: [
|
||||
'src/main/startup/',
|
||||
'src/shared/worktree/',
|
||||
'config/scripts/localization/source-extraction/audit-localization-coverage',
|
||||
'config/scripts/localization/source-extraction/localization-visible-object-keys',
|
||||
'config/startup-worktree-localization-allowlist.json'
|
||||
]
|
||||
},
|
||||
{
|
||||
name: 'mobile localization',
|
||||
@@ -144,7 +172,8 @@ export const VERIFY_CHECKS = [
|
||||
'mobile/web-entry/',
|
||||
'config/mobile-localization-coverage-allowlist.json',
|
||||
'config/scripts/audit-localization-coverage',
|
||||
'config/scripts/localization/source-extraction/audit-localization-coverage'
|
||||
'config/scripts/localization/source-extraction/audit-localization-coverage',
|
||||
'config/scripts/localization/source-extraction/localization-visible-object-keys'
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
@@ -18,6 +18,7 @@ export const LINT_STEPS = [
|
||||
'check:test-file-runners',
|
||||
'verify:localization-catalogs',
|
||||
'verify:localization-coverage',
|
||||
'verify:startup-worktree-localization-coverage',
|
||||
'verify:mobile-localization',
|
||||
'verify:mobile-localization-coverage',
|
||||
'lint:ast-grep-gates',
|
||||
@@ -39,6 +40,8 @@ export const LINT_STEPS = [
|
||||
'check:mobile-shared-dependency-versions',
|
||||
'check:ts-nocheck-ratchet',
|
||||
'check:workspace-record-read-ratchet',
|
||||
'check:tab-map-seam-ratchet',
|
||||
'check:terminal-parking-ownership-ratchet',
|
||||
'check:unproven-pty-retirement-ratchet',
|
||||
'check:daemon-blocking-call-ratchet',
|
||||
'check:main-sync-fs-ratchet',
|
||||
|
||||
@@ -13,20 +13,6 @@ const checks = [
|
||||
args: ['test', '--package-path', 'native/computer-use-macos'],
|
||||
enabled: process.platform === 'darwin'
|
||||
},
|
||||
{
|
||||
name: 'Linux provider Python syntax',
|
||||
command: 'python3',
|
||||
args: [
|
||||
'-c',
|
||||
[
|
||||
'import ast, pathlib',
|
||||
'source=pathlib.Path("native/computer-use-linux/runtime.py").read_text(encoding="utf-8")',
|
||||
'ast.parse(source)',
|
||||
'print("syntax-ok")'
|
||||
].join(';')
|
||||
],
|
||||
enabled: true
|
||||
},
|
||||
{
|
||||
name: 'Linux snapshot renderer tests',
|
||||
command: 'python3',
|
||||
|
||||
@@ -299,7 +299,7 @@ function renderEvents({ events, eventContribution, typeText }, { services, frame
|
||||
const { REFERENCE_TYPE_TEXT, zodTypeText } = typeText
|
||||
const workerEvents = eventContribution.PLUGIN_EVENT_NAMES.map(
|
||||
(name) =>
|
||||
`- ${code(name)} (capability ${code(eventContribution.PLUGIN_EVENT_CAPABILITY[name])}; since ${eventContribution.PLUGIN_EVENT_SINCE[name]}): ${events.PLUGIN_EVENT_SUMMARIES[name]}\n ${code(zodTypeText(events.PLUGIN_EVENT_PAYLOAD_SCHEMAS[name], 'output', REFERENCE_TYPE_TEXT))}`
|
||||
`- ${code(name)} (${eventContribution.PLUGIN_EVENT_CAPABILITY[name] ? `capability ${code(eventContribution.PLUGIN_EVENT_CAPABILITY[name])}` : 'no capability'}; since ${eventContribution.PLUGIN_EVENT_SINCE[name]}): ${events.PLUGIN_EVENT_SUMMARIES[name]}\n ${code(zodTypeText(events.PLUGIN_EVENT_PAYLOAD_SCHEMAS[name], 'output', REFERENCE_TYPE_TEXT))}`
|
||||
)
|
||||
return document(
|
||||
'Events',
|
||||
|
||||
@@ -27,6 +27,10 @@ import {
|
||||
renderLiveReadLines,
|
||||
renderStoreReadLines
|
||||
} from './react-compiler-hazards.mjs'
|
||||
import {
|
||||
UNCOMPILED_LIST,
|
||||
readListedFiles
|
||||
} from '../../../../build-plugins/react-compiler-uncompiled-files.mjs'
|
||||
|
||||
// Runs React Compiler (analysis only, nothing is written) over the renderer so code that compiles
|
||||
// today keeps compiling, and code that would change behavior once compiled can't be added.
|
||||
@@ -34,8 +38,6 @@ import {
|
||||
const SCAN_ROOT = 'src/renderer/src'
|
||||
const BAILOUT_BASELINE = 'config/react-compiler-bailout-baseline.txt'
|
||||
const HAZARD_BASELINE = 'config/react-compiler-hazard-baseline.txt'
|
||||
// The build leaves these files uncompiled, so their hazards cannot run.
|
||||
const UNCOMPILED_LIST = 'config/react-compiler-uncompiled-files.txt'
|
||||
const COMMAND = 'pnpm check:react-compiler-compat-ratchet'
|
||||
const NOT_SHIPPED =
|
||||
/(?:^|\/)__(?:mocks|fixtures|tests)__\/|\.(?:test|spec|bench)\.[cm]?tsx?$|[.-]test-|[.-]fixtures?\.tsx?$/
|
||||
@@ -101,18 +103,31 @@ function addTo(map, key, value) {
|
||||
map.set(key, [...(map.get(key) ?? []), value])
|
||||
}
|
||||
|
||||
// The build leaves these files uncompiled, so their hazards cannot run.
|
||||
function readUncompiledFiles(root) {
|
||||
const file = path.join(root, UNCOMPILED_LIST)
|
||||
if (!fs.existsSync(file)) {
|
||||
return new Set()
|
||||
return fs.existsSync(path.join(root, UNCOMPILED_LIST))
|
||||
? new Set(readListedFiles(UNCOMPILED_LIST, root))
|
||||
: new Set()
|
||||
}
|
||||
|
||||
// Why: the build matches the exact id, so `\`, `../`, a directory or another case would silently compile.
|
||||
function isCanonicalFile(root, rel) {
|
||||
try {
|
||||
const file = path.join(root, rel)
|
||||
return (
|
||||
!rel.includes('\\') &&
|
||||
path.posix.normalize(rel) === rel &&
|
||||
fs.statSync(file).isFile() &&
|
||||
fs.realpathSync.native(file) === path.join(fs.realpathSync.native(root), rel)
|
||||
)
|
||||
} catch {
|
||||
return false
|
||||
}
|
||||
return new Set(
|
||||
fs
|
||||
.readFileSync(file, 'utf8')
|
||||
.split('\n')
|
||||
.map((line) => line.trim())
|
||||
.filter((line) => line && !line.startsWith('#'))
|
||||
)
|
||||
}
|
||||
|
||||
/** Listed paths that name no renderer file; a renamed file would silently compile. */
|
||||
export function findStaleUncompiledFiles(uncompiled, exists) {
|
||||
return [...uncompiled].filter((rel) => !rel.startsWith(`${SCAN_ROOT}/`) || !exists(rel))
|
||||
}
|
||||
|
||||
/** Virtualizer hooks plus every hook that returns one, followed through wrappers of wrappers. */
|
||||
@@ -210,12 +225,14 @@ async function scanFile(rel, text, result) {
|
||||
|
||||
export async function scanRenderer(root = process.cwd()) {
|
||||
const sources = [...readTrackedSources(root, [SCAN_ROOT], isScannedPath)]
|
||||
const uncompiled = readUncompiledFiles(root)
|
||||
const result = {
|
||||
files: 0,
|
||||
compiled: 0,
|
||||
diagnostics: new Map(),
|
||||
hazards: new Map(),
|
||||
uncompiled: readUncompiledFiles(root),
|
||||
uncompiled,
|
||||
staleUncompiled: findStaleUncompiledFiles(uncompiled, (rel) => isCanonicalFile(root, rel)),
|
||||
virtualizerHooks: collectVirtualizerHooks(sources),
|
||||
liveReaders: collectLiveReaders(sources)
|
||||
}
|
||||
@@ -341,8 +358,15 @@ export async function main(root = process.cwd(), arg = undefined) {
|
||||
)
|
||||
return 0
|
||||
}
|
||||
for (const rel of scan.staleUncompiled) {
|
||||
console.error(
|
||||
`::error::${UNCOMPILED_LIST}: ${rel} is not a renderer file. ` +
|
||||
'Point it at the renamed file, or remove it once the file is gone.'
|
||||
)
|
||||
}
|
||||
const touched = listTouchedFiles(root)
|
||||
const ok = [
|
||||
scan.staleUncompiled.length === 0,
|
||||
check(root, 'bailout(s)', BAILOUT_BASELINE, bailouts, scan.diagnostics, touched),
|
||||
check(root, 'hazard(s)', HAZARD_BASELINE, hazards, scan.hazards, touched)
|
||||
].every(Boolean)
|
||||
|
||||
@@ -320,6 +320,24 @@ function isSameNameCopy(property, name) {
|
||||
return ts.isPropertyAccessExpression(value) && value.name.text === name
|
||||
}
|
||||
|
||||
// The transition seam names the fields it tracks in `const SEAM_*_FIELDS = [...] as const` lists; names, not writes.
|
||||
function isSeamFieldNameConstant(literal) {
|
||||
let list = literal.parent
|
||||
if (!ts.isArrayLiteralExpression(list)) {
|
||||
return false
|
||||
}
|
||||
let declaration = list.parent
|
||||
while (ts.isAsExpression(declaration) || ts.isSatisfiesExpression(declaration)) {
|
||||
declaration = declaration.parent
|
||||
}
|
||||
return (
|
||||
ts.isVariableDeclaration(declaration) &&
|
||||
ts.isIdentifier(declaration.name) &&
|
||||
/^SEAM_[A-Z_]+_FIELDS$/.test(declaration.name.text) &&
|
||||
(declaration.parent.flags & ts.NodeFlags.Const) !== 0
|
||||
)
|
||||
}
|
||||
|
||||
/** Layout writes in one file under one ratchet's rules. */
|
||||
export function countLayoutWrites(sourceText, ratchet, fileName = 'file.tsx') {
|
||||
const names = [...ratchet.writerNames, ...ratchet.assignedFields]
|
||||
@@ -392,7 +410,8 @@ export function countLayoutWrites(sourceText, ratchet, fileName = 'file.tsx') {
|
||||
node.parent.expression.expression.text === 'Object' &&
|
||||
node.parent.expression.name.text === 'hasOwn'
|
||||
) &&
|
||||
!ts.isLiteralTypeNode(node.parent)
|
||||
!ts.isLiteralTypeNode(node.parent) &&
|
||||
!isSeamFieldNameConstant(node)
|
||||
) {
|
||||
count += 1
|
||||
}
|
||||
|
||||
@@ -0,0 +1,380 @@
|
||||
import fs from 'node:fs'
|
||||
import path from 'node:path'
|
||||
import process from 'node:process'
|
||||
import { pathToFileURL } from 'node:url'
|
||||
import ts from 'typescript-api'
|
||||
|
||||
// The tab-map transition seam (store/keyed-record-transitions.ts) only works if its writers annotate and its
|
||||
// consumers enumerate whole maps only on named cold paths; this pins both for the repaired modules, nothing wider.
|
||||
|
||||
const R = 'src/renderer/src/'
|
||||
const STATUS = `${R}components/native-chat/session/status/`
|
||||
|
||||
/**
|
||||
* Repaired consumers: the only functions allowed to walk a whole map (`coldPaths`), which callers
|
||||
* may reach a cold helper (`helpers`), and the only values they may import, so a new walking helper
|
||||
* can't arrive through an import unreviewed.
|
||||
*/
|
||||
export const CONSUMERS = new Map([
|
||||
[
|
||||
`${STATUS}structured-agent-session-tabs.ts`,
|
||||
{
|
||||
coldPaths: new Set(['rebuildFromSnapshot']),
|
||||
helpers: { rebuildFromSnapshot: ['advance'] },
|
||||
imports: new Set(['structuredAgentSessionPaneKey', 'isStructuredTab', 'readTabMapChanges'])
|
||||
}
|
||||
],
|
||||
[
|
||||
`${STATUS}StructuredAgentSessionStatusBridge.tsx`,
|
||||
{
|
||||
coldPaths: new Set(['reconcileFromSnapshot']),
|
||||
helpers: {
|
||||
getStructuredAgentSessionTabs: ['reconcileFromSnapshot'],
|
||||
reconcileFromSnapshot: ['reconcile']
|
||||
},
|
||||
imports: new Set([
|
||||
'useEffect',
|
||||
'projectStatus',
|
||||
'getStructuredAgentSessionLaunchLifecycle',
|
||||
'subscribeStructuredAgentLaunchStatus',
|
||||
'getStructuredAgentSessionLaunchFailedAt',
|
||||
'useAppStore',
|
||||
'structuredAgentSessionTargetForHost',
|
||||
'getStructuredAgentSessionStatusFeed',
|
||||
'structuredAgentSessionStatusFeedKey',
|
||||
'getStructuredAgentSessionTabs',
|
||||
'getStructuredAgentSessionTabsInWorkspace',
|
||||
'readTabMapChanges',
|
||||
'createTabOwnerCache',
|
||||
'ownerInputChanged',
|
||||
'ownerInputs',
|
||||
'createStructuredSessionMembership',
|
||||
'sameSemanticTab'
|
||||
])
|
||||
}
|
||||
],
|
||||
[
|
||||
`${STATUS}structured-agent-session-status-membership.ts`,
|
||||
{
|
||||
coldPaths: new Set(),
|
||||
helpers: { getStructuredAgentSessionTabs: [] },
|
||||
imports: new Set(['structuredAgentSessionPaneKey'])
|
||||
}
|
||||
]
|
||||
])
|
||||
const ENUMERATING_CALLS = new Set(['keys', 'values', 'entries'])
|
||||
|
||||
/** Shared tab-map writers wired to the seam: a raw record literal for these fields bypasses provenance. */
|
||||
export const WRITERS = [
|
||||
'src/renderer/src/runtime/web-session-tabs-sync/scoped-patch-annotation.ts',
|
||||
'src/renderer/src/runtime/web-session-tabs-sync/store-patch.ts',
|
||||
'src/renderer/src/runtime/workspace-layout/frames/workspace-layout-frame-sync.ts',
|
||||
'src/renderer/src/store/slices/browser/pages/browser-page-state-actions.ts',
|
||||
'src/renderer/src/store/slices/editor/file-ids/hydrated-editor-file-ids.ts',
|
||||
'src/renderer/src/store/slices/editor/hydration/restored-editor-owner-in-place.ts',
|
||||
'src/renderer/src/store/slices/editor/hydration/restored-editor-owner-transition.ts',
|
||||
'src/renderer/src/store/slices/editor/markdown/markdown-preview-actions.ts',
|
||||
'src/renderer/src/store/slices/editor/opening/open-file-mutations.ts',
|
||||
'src/renderer/src/store/slices/ssh/ssh-target-cleanup.ts',
|
||||
'src/renderer/src/store/slices/tabs/rename-worktree-layout.ts',
|
||||
'src/renderer/src/store/slices/tabs/tab-group-state.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-close-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-create-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-drag-preview-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-drop-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-focus-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-group-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-host-mirroring.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-label-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-move-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-reconciliation.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-session-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/tabs-split-ratio-actions.ts',
|
||||
'src/renderer/src/store/slices/tabs/worktree-layout-lifecycle.ts',
|
||||
'src/renderer/src/store/slices/tabs/worktree-terminal-tab-respawn.ts',
|
||||
'src/renderer/src/store/slices/worktrees/session/set-active-worktree.ts',
|
||||
'src/renderer/src/store/slices/worktrees/session/worktree-identity-rename-state.ts',
|
||||
'src/renderer/src/store/slices/worktrees/session/worktree-slice-lookups.ts',
|
||||
'src/renderer/src/store/slices/worktrees/teardown/record-key-omission.ts',
|
||||
'src/renderer/src/store/terminals/terminal-tab-close.ts',
|
||||
'src/renderer/src/store/terminals/terminal-tab-creation.ts',
|
||||
'src/renderer/src/store/terminals/terminal-tab-navigation.ts',
|
||||
'src/renderer/src/store/terminals/terminal-tab-title-batch.ts',
|
||||
'src/renderer/src/store/terminals/workspace-terminal-hydration-patch.ts',
|
||||
'src/renderer/src/store/terminals/workspace-terminal-hydration.ts',
|
||||
'src/renderer/src/store/terminals/workspace-terminal-reconnect.ts',
|
||||
'src/renderer/src/store/workspace-layout/frames/workspace-layout-frame-store-patch.ts'
|
||||
]
|
||||
export const SEAM_FIELDS = new Set([
|
||||
'tabsByWorktree',
|
||||
'unifiedTabsByWorktree',
|
||||
'terminalLayoutsByTabId',
|
||||
'ptyIdsByTabId',
|
||||
'lastKnownRelayPtyIdByTabId',
|
||||
'runtimePaneTitlesByTabId',
|
||||
'pendingStartupByTabId',
|
||||
'pendingReconnectPtyIdByTabId',
|
||||
'sleepingAgentSessionsByPaneKey',
|
||||
'layoutByWorktree',
|
||||
'groupsByWorktree',
|
||||
'activeGroupIdByWorktree'
|
||||
])
|
||||
|
||||
function parse(file, text) {
|
||||
return ts.createSourceFile(file, text, ts.ScriptTarget.Latest, true, ts.ScriptKind.TSX)
|
||||
}
|
||||
|
||||
function line(source, node) {
|
||||
return source.getLineAndCharacterOfPosition(node.getStart(source)).line + 1
|
||||
}
|
||||
|
||||
function enclosingFunctionNames(node) {
|
||||
const names = []
|
||||
for (let current = node.parent; current; current = current.parent) {
|
||||
if (ts.isFunctionDeclaration(current) && current.name) {
|
||||
names.push(current.name.text)
|
||||
} else if (
|
||||
(ts.isArrowFunction(current) || ts.isFunctionExpression(current)) &&
|
||||
ts.isVariableDeclaration(current.parent) &&
|
||||
ts.isIdentifier(current.parent.name)
|
||||
) {
|
||||
names.push(current.parent.name.text)
|
||||
}
|
||||
}
|
||||
return names
|
||||
}
|
||||
|
||||
function valueImports(source) {
|
||||
const imported = []
|
||||
for (const statement of source.statements) {
|
||||
const clause = ts.isImportDeclaration(statement) ? statement.importClause : null
|
||||
if (!clause || clause.isTypeOnly) {
|
||||
continue
|
||||
}
|
||||
if (clause.name) {
|
||||
imported.push(clause.name)
|
||||
}
|
||||
const bindings = clause.namedBindings
|
||||
if (bindings && ts.isNamespaceImport(bindings)) {
|
||||
imported.push(bindings.name)
|
||||
} else if (bindings) {
|
||||
imported.push(
|
||||
...bindings.elements.filter((element) => !element.isTypeOnly).map((e) => e.name)
|
||||
)
|
||||
}
|
||||
}
|
||||
return imported
|
||||
}
|
||||
|
||||
function isHelperReference(node, helpers) {
|
||||
if (!ts.isIdentifier(node) || !Object.hasOwn(helpers, node.text)) {
|
||||
return false
|
||||
}
|
||||
const parent = node.parent
|
||||
const declares =
|
||||
((ts.isVariableDeclaration(parent) || ts.isFunctionDeclaration(parent)) &&
|
||||
parent.name === node) ||
|
||||
(ts.isPropertyAccessExpression(parent) && parent.name === node) ||
|
||||
(ts.isPropertyAssignment(parent) && parent.name === node) ||
|
||||
ts.isImportSpecifier(parent)
|
||||
return !declares
|
||||
}
|
||||
|
||||
export function consumerViolations(file, text, { coldPaths, helpers, imports }) {
|
||||
const source = parse(file, text)
|
||||
const violations = []
|
||||
for (const name of valueImports(source)) {
|
||||
if (!imports.has(name.text)) {
|
||||
violations.push(
|
||||
`${file}:${line(source, name)} imports ${name.text}; repaired consumers import only reviewed helpers`
|
||||
)
|
||||
}
|
||||
}
|
||||
const visit = (node) => {
|
||||
let what = null
|
||||
let allowed = coldPaths
|
||||
if (
|
||||
ts.isPropertyAccessExpression(node) &&
|
||||
ts.isIdentifier(node.expression) &&
|
||||
node.expression.text === 'Object' &&
|
||||
ENUMERATING_CALLS.has(node.name.text)
|
||||
) {
|
||||
// Any reference, called or aliased (`const keys = Object.keys`).
|
||||
what = `Object.${node.name.text}`
|
||||
} else if (isHelperReference(node, helpers)) {
|
||||
// Calls, aliases (`const resync = reconcileFromSnapshot`) and callbacks alike.
|
||||
what = `${node.text}()`
|
||||
allowed = new Set(helpers[node.text])
|
||||
} else if (ts.isForInStatement(node)) {
|
||||
what = 'for…in'
|
||||
}
|
||||
if (what && !enclosingFunctionNames(node).some((name) => allowed.has(name))) {
|
||||
violations.push(`${file}:${line(source, node)} ${what} outside a named cold path`)
|
||||
}
|
||||
if (
|
||||
ts.isFunctionDeclaration(node) &&
|
||||
node.name?.text === 'rebuildFromSnapshot' &&
|
||||
node.modifiers?.some((modifier) => modifier.kind === ts.SyntaxKind.ExportKeyword)
|
||||
) {
|
||||
violations.push(`${file}:${line(source, node)} rebuildFromSnapshot must stay module-private`)
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(source)
|
||||
return violations
|
||||
}
|
||||
|
||||
function isRawRecord(expression) {
|
||||
if (ts.isObjectLiteralExpression(expression)) {
|
||||
return expression.properties.some((property) => ts.isSpreadAssignment(property))
|
||||
}
|
||||
return (
|
||||
ts.isCallExpression(expression) &&
|
||||
ts.isPropertyAccessExpression(expression.expression) &&
|
||||
ts.isIdentifier(expression.expression.expression) &&
|
||||
expression.expression.expression.text === 'Object' &&
|
||||
['fromEntries', 'assign'].includes(expression.expression.name.text)
|
||||
)
|
||||
}
|
||||
|
||||
// Only an explicit cold-path mark certifies a record built outside a construction helper or draft.
|
||||
const ANNOTATED_ARGUMENT = {
|
||||
markFullResync: 0
|
||||
}
|
||||
|
||||
function enclosingScope(node) {
|
||||
let current = node.parent
|
||||
while (current && !ts.isFunctionLike(current) && !ts.isSourceFile(current)) {
|
||||
current = current.parent
|
||||
}
|
||||
return current
|
||||
}
|
||||
|
||||
/** The value a local name holds at `use`: its declaration's initializer, followed through aliases. */
|
||||
function bindingSource(name, scope, use, seen = new Set()) {
|
||||
if (seen.has(name)) {
|
||||
return null
|
||||
}
|
||||
seen.add(name)
|
||||
let found = null
|
||||
const visit = (node) => {
|
||||
if (node.pos >= use.pos) {
|
||||
return
|
||||
}
|
||||
if (ts.isVariableDeclaration(node) && ts.isIdentifier(node.name) && node.name.text === name) {
|
||||
found = node.initializer ?? null
|
||||
} else if (
|
||||
ts.isBinaryExpression(node) &&
|
||||
node.operatorToken.kind === ts.SyntaxKind.EqualsToken &&
|
||||
ts.isIdentifier(node.left) &&
|
||||
node.left.text === name
|
||||
) {
|
||||
found = node.right
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(scope)
|
||||
if (found && ts.isIdentifier(found)) {
|
||||
const aliased = bindingSource(found.text, scope, use, seen)
|
||||
return aliased && { ...aliased, names: [name, ...aliased.names] }
|
||||
}
|
||||
return found && { value: found, names: [name] }
|
||||
}
|
||||
|
||||
/** Whether a seam helper annotates one of `names` in place before `use` publishes it. */
|
||||
function annotatedBefore(names, scope, use) {
|
||||
let annotated = false
|
||||
const visit = (node) => {
|
||||
if (node.pos >= use.pos) {
|
||||
return
|
||||
}
|
||||
if (
|
||||
node.end <= use.pos &&
|
||||
ts.isCallExpression(node) &&
|
||||
ts.isIdentifier(node.expression) &&
|
||||
Object.hasOwn(ANNOTATED_ARGUMENT, node.expression.text)
|
||||
) {
|
||||
const argument = node.arguments[ANNOTATED_ARGUMENT[node.expression.text]]
|
||||
annotated ||=
|
||||
argument !== undefined && ts.isIdentifier(argument) && names.includes(argument.text)
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(scope)
|
||||
return annotated
|
||||
}
|
||||
|
||||
function rawValue(node) {
|
||||
const initializer = ts.isShorthandPropertyAssignment(node) ? node.name : node.initializer
|
||||
if (isRawRecord(initializer)) {
|
||||
return true
|
||||
}
|
||||
if (!ts.isIdentifier(initializer)) {
|
||||
return false
|
||||
}
|
||||
// Follow the local binding and its aliases; the record must be annotated before it is published.
|
||||
for (let scope = enclosingScope(node); scope; scope = scope.parent && enclosingScope(scope)) {
|
||||
const binding = bindingSource(initializer.text, scope, node)
|
||||
if (binding) {
|
||||
return isRawRecord(binding.value) && !annotatedBefore(binding.names, scope, node)
|
||||
}
|
||||
if (ts.isSourceFile(scope)) {
|
||||
break
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
export function writerViolations(file, text) {
|
||||
const source = parse(file, text)
|
||||
const violations = []
|
||||
const visit = (node) => {
|
||||
if (
|
||||
(ts.isPropertyAssignment(node) || ts.isShorthandPropertyAssignment(node)) &&
|
||||
(ts.isIdentifier(node.name) || ts.isStringLiteral(node.name)) &&
|
||||
SEAM_FIELDS.has(node.name.text) &&
|
||||
rawValue(node)
|
||||
) {
|
||||
violations.push(
|
||||
`${file}:${line(source, node)} raw ${node.name.text} record; build it with a replace helper or draft, or mark it full resync`
|
||||
)
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(source)
|
||||
return violations
|
||||
}
|
||||
|
||||
export function collect(root = process.cwd()) {
|
||||
const violations = []
|
||||
for (const [file, rules] of CONSUMERS) {
|
||||
violations.push(
|
||||
...consumerViolations(file, fs.readFileSync(path.join(root, file), 'utf8'), rules)
|
||||
)
|
||||
}
|
||||
for (const file of WRITERS) {
|
||||
violations.push(...writerViolations(file, fs.readFileSync(path.join(root, file), 'utf8')))
|
||||
}
|
||||
return violations
|
||||
}
|
||||
|
||||
export function main(root = process.cwd()) {
|
||||
const violations = collect(root)
|
||||
if (violations.length) {
|
||||
for (const violation of violations) {
|
||||
console.error(violation)
|
||||
}
|
||||
console.error(
|
||||
'Tab-map seam: ordinary handlers use addressed deltas (readTabMapChanges); whole-map walks belong only in the named cold paths.'
|
||||
)
|
||||
return 1
|
||||
}
|
||||
console.log(
|
||||
`tab-map-seam ratchet OK — ${CONSUMERS.size} consumer and ${WRITERS.length} writer modules pinned.`
|
||||
)
|
||||
return 0
|
||||
}
|
||||
|
||||
if (process.argv[1] && import.meta.url === pathToFileURL(process.argv[1]).href) {
|
||||
process.exit(main(process.cwd()))
|
||||
}
|
||||
@@ -0,0 +1,475 @@
|
||||
import fs from 'node:fs'
|
||||
import path from 'node:path'
|
||||
import process from 'node:process'
|
||||
import { pathToFileURL } from 'node:url'
|
||||
import ts from 'typescript-api'
|
||||
|
||||
const RENDERER = 'src/renderer/src/'
|
||||
const WATCHERS = `${RENDERER}components/terminal-pane/parking/output-watchers/`
|
||||
const ROOTS = new Map([
|
||||
[
|
||||
`${RENDERER}components/terminal/terminal-provider-snapshot-bound-pty-ids.ts`,
|
||||
['createTerminalProviderSnapshotBoundPtyIdsSelector']
|
||||
],
|
||||
[`${RENDERER}components/use-terminal-watcher-effects.ts`, ['useTerminalWatcherEffects']],
|
||||
[`${RENDERER}components/use-terminal-parking-pass.ts`, ['useTerminalParkingPass']],
|
||||
[
|
||||
`${RENDERER}components/terminal-parking-pass-candidates.ts`,
|
||||
['collectTerminalParkingPassCandidates']
|
||||
],
|
||||
[`${RENDERER}components/terminal/split-group-mount.ts`, ['anyMountedWorktreeHasLayout']],
|
||||
[
|
||||
`${RENDERER}components/terminal-pane/parking/lifecycle/use-parked-terminal-watcher-synchronization.ts`,
|
||||
['useParkedTerminalWatcherSynchronization']
|
||||
],
|
||||
[
|
||||
`${RENDERER}components/terminal-pane/parking/lifecycle/use-terminal-tab-cold-parking.ts`,
|
||||
['useTerminalTabColdParking']
|
||||
],
|
||||
[`${WATCHERS}terminal-parked-tab-watchers.ts`, ['syncParkedTerminalTabWatchers']],
|
||||
[`${WATCHERS}parked-terminal-tab-coverage.ts`, ['canWatcherCoverParkedTerminalTab']],
|
||||
[
|
||||
`${RENDERER}lib/agent-session/resume/resume-sleeping-agent-session.ts`,
|
||||
['resumeSleepingAgentSessionsForWorktree']
|
||||
]
|
||||
])
|
||||
const HOT_MAPS = new Set([
|
||||
'tabsByWorktree',
|
||||
'unifiedTabsByWorktree',
|
||||
'terminalLayoutsByTabId',
|
||||
'sleepingAgentSessionsByPaneKey'
|
||||
])
|
||||
const OWNER_ROOTS = [
|
||||
{
|
||||
rel: 'store/terminals/terminal-parking-input-owner.ts',
|
||||
name: 'acceptTerminalParkingInputs',
|
||||
inputs: []
|
||||
},
|
||||
{
|
||||
rel: 'store/terminals/terminal-parking-input-owner.ts',
|
||||
name: 'publishAcceptedTerminalParkingInputs',
|
||||
inputs: []
|
||||
},
|
||||
{
|
||||
rel: 'store/terminals/terminal-parking-input-owner.ts',
|
||||
name: 'invalidateTerminalParkingPtyInputs',
|
||||
inputs: []
|
||||
},
|
||||
{
|
||||
rel: 'store/terminals/terminal-tab-owner-index.ts',
|
||||
name: 'update',
|
||||
inputs: ['tabsByWorktree']
|
||||
},
|
||||
{ rel: 'store/terminals/sleeping-agent-record-index.ts', name: 'update', inputs: ['records'] },
|
||||
{
|
||||
rel: 'store/terminals/sleeping-agent-record-index.ts',
|
||||
name: 'acceptTransition',
|
||||
inputs: ['previous', 'next']
|
||||
},
|
||||
{
|
||||
rel: 'lib/workspace/tabs/worktree-tab-bucket-projection.ts',
|
||||
name: 'project',
|
||||
inputs: ['source']
|
||||
}
|
||||
]
|
||||
const KEY_DIFFS = new Set([
|
||||
`${RENDERER}store/terminals/terminal-parking-input-owner.ts#diffUnknownParkingRecordKeys`,
|
||||
`${RENDERER}store/terminals/terminal-tab-owner-index.ts#diffUnknownTabOwnerKeys`,
|
||||
`${RENDERER}store/terminals/sleeping-agent-record-index.ts#diffUnknownSleepingRecordKeys`,
|
||||
`${RENDERER}lib/workspace/tabs/worktree-tab-bucket-projection.ts#diffUnknownProjectionKeys`
|
||||
])
|
||||
const COLD_RESYNCS = new Set([
|
||||
`${RENDERER}store/terminals/terminal-parking-input-owner.ts#resyncTerminalParkingWorkspaceIds`,
|
||||
`${RENDERER}store/terminals/sleeping-agent-record-index.ts#resyncSleepingAgentRecordKeys`
|
||||
])
|
||||
|
||||
function isColdResyncCall(node, source) {
|
||||
for (let ancestor = node.parent; ancestor; ancestor = ancestor.parent) {
|
||||
if (
|
||||
ts.isConditionalExpression(ancestor) &&
|
||||
ancestor.condition.getText(source) === 'previous' &&
|
||||
node.pos >= ancestor.whenFalse.pos
|
||||
) {
|
||||
return true
|
||||
}
|
||||
if (
|
||||
ts.isBinaryExpression(ancestor) &&
|
||||
ancestor.operatorToken.kind === ts.SyntaxKind.QuestionQuestionToken &&
|
||||
ancestor.left.getText(source) === 'keys'
|
||||
) {
|
||||
return true
|
||||
}
|
||||
if (
|
||||
ts.isIfStatement(ancestor) &&
|
||||
node.pos >= ancestor.thenStatement.pos &&
|
||||
node.end <= ancestor.thenStatement.end
|
||||
) {
|
||||
const condition = ancestor.expression.getText(source).replace(/\s+/g, ' ')
|
||||
if (
|
||||
condition === 'ptyIds === undefined' ||
|
||||
condition.includes(
|
||||
'previous.settings?.terminalSshViewParking !== state.settings?.terminalSshViewParking'
|
||||
)
|
||||
) {
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
const STORE_BOUNDARIES = new Set([`${RENDERER}store/index.ts`, `${RENDERER}store.ts`])
|
||||
// Resource delivery and startup recovery are separate entry points, not parking input discovery.
|
||||
const EFFECT_BOUNDARIES = new Set([
|
||||
`${RENDERER}components/terminal/terminal-provider-snapshot-bound-pty-ids.ts#resyncUnknownSnapshot`,
|
||||
`${RENDERER}components/terminal/use-terminal-startup-activation.ts#useTerminalStartupActivation`,
|
||||
`${WATCHERS}terminal-parked-pty-watcher.ts#startParkedPtyWatcher`,
|
||||
`${RENDERER}components/terminal-pane/parking/capture/parked-terminal-buffer-capture.ts#captureParkedTerminalBuffers`,
|
||||
`${RENDERER}lib/agent-session/resume/sleeping-agent-session-launch.ts#launchSleepingAgentSession`,
|
||||
`${RENDERER}lib/host-mirror-handle-gap-wait.ts#parkUntilHostMirrorHandleLands`,
|
||||
`${RENDERER}runtime/web-session-tabs-sync/hydration/host-session-mirror-hydration.ts#parkUntilHostSessionMirrorHydrates`
|
||||
])
|
||||
const ENUMERATORS = new Set(['entries', 'values', 'keys', 'assign'])
|
||||
|
||||
const ADDRESSED_FIELDS = new Set([
|
||||
'terminalLayoutsByTabId',
|
||||
'ptyIdsByTabId',
|
||||
'lastKnownRelayPtyIdByTabId',
|
||||
'runtimePaneTitlesByTabId',
|
||||
'pendingStartupByTabId',
|
||||
'sleepingAgentSessionsByPaneKey'
|
||||
])
|
||||
const ORDINARY_WRITERS = [
|
||||
'store/terminals/terminal-layout-state.ts',
|
||||
'store/terminals/terminal-pane-hibernation.ts',
|
||||
'store/terminals/terminal-pty-bindings.ts',
|
||||
'store/terminals/terminal-pty-release.ts',
|
||||
'store/terminals/terminal-orphan-cleanup.ts',
|
||||
'store/terminals/terminal-startup-queues.ts',
|
||||
'store/terminals/terminal-tab-presentation.ts',
|
||||
'store/terminals/terminal-shutdown-state.ts',
|
||||
'store/terminals/window-tab-start-in-main.ts',
|
||||
'store/slices/agent-status/agent-status-live-reducer.ts',
|
||||
'store/slices/agent-status/agent-status-launch-actions.ts',
|
||||
'store/slices/agent-status/agent-status-provider-session-actions.ts',
|
||||
'store/slices/agent-status/agent-status-recovery-actions.ts',
|
||||
'store/slices/agent-status/agent-status-authority-actions.ts'
|
||||
].map((rel) => RENDERER + rel)
|
||||
const RECORD_TRANSITIONS = new Set([
|
||||
'replaceRecordEntries',
|
||||
'removePaneKeys',
|
||||
'removePaneKeysByTabPrefix'
|
||||
])
|
||||
|
||||
function collectUnaddressedWrites(root) {
|
||||
const violations = []
|
||||
for (const rel of ORDINARY_WRITERS) {
|
||||
const { source, aliases, assignments } = readModule(root, rel)
|
||||
function addressed(value, field, seen = new Set()) {
|
||||
if (ts.isCallExpression(value) && ts.isIdentifier(value.expression)) {
|
||||
return RECORD_TRANSITIONS.has(value.expression.text)
|
||||
}
|
||||
if (ts.isPropertyAccessExpression(value)) {
|
||||
return value.name.text === field
|
||||
}
|
||||
if (ts.isConditionalExpression(value)) {
|
||||
return addressed(value.whenTrue, field, seen) && addressed(value.whenFalse, field, seen)
|
||||
}
|
||||
if (ts.isIdentifier(value)) {
|
||||
if (seen.has(value.text)) {
|
||||
return false
|
||||
}
|
||||
seen.add(value.text)
|
||||
const alias = aliases.get(value.text)
|
||||
return (
|
||||
alias !== undefined &&
|
||||
[alias, ...(assignments.get(value.text) ?? [])].every((replacement) =>
|
||||
addressed(replacement, field, new Set(seen))
|
||||
)
|
||||
)
|
||||
}
|
||||
return false
|
||||
}
|
||||
function visit(node) {
|
||||
if (ts.isPropertyAssignment(node) || ts.isShorthandPropertyAssignment(node)) {
|
||||
const field =
|
||||
ts.isIdentifier(node.name) || ts.isStringLiteral(node.name) ? node.name.text : null
|
||||
const value = ts.isPropertyAssignment(node) ? node.initializer : node.name
|
||||
if (ADDRESSED_FIELDS.has(field) && !addressed(value, field)) {
|
||||
const line = source.getLineAndCharacterOfPosition(node.getStart(source)).line + 1
|
||||
violations.push(`${rel}:${line}: ${field} write needs complete record-key provenance.`)
|
||||
}
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(source)
|
||||
}
|
||||
return violations
|
||||
}
|
||||
|
||||
function resolveImport(root, from, specifier) {
|
||||
const base = specifier.startsWith('@/')
|
||||
? RENDERER + specifier.slice(2)
|
||||
: specifier.startsWith('.')
|
||||
? path.posix.join(path.posix.dirname(from), specifier)
|
||||
: null
|
||||
if (!base) {
|
||||
return null
|
||||
}
|
||||
return (
|
||||
[base, `${base}.ts`, `${base}.tsx`, `${base}/index.ts`].find(
|
||||
(candidate) =>
|
||||
fs.existsSync(path.join(root, candidate)) &&
|
||||
fs.statSync(path.join(root, candidate)).isFile()
|
||||
) ?? null
|
||||
)
|
||||
}
|
||||
|
||||
function readModule(root, rel) {
|
||||
const source = ts.createSourceFile(
|
||||
rel,
|
||||
fs.readFileSync(path.join(root, rel), 'utf8'),
|
||||
ts.ScriptTarget.Latest,
|
||||
true
|
||||
)
|
||||
const imports = new Map()
|
||||
const functions = new Map()
|
||||
const aliases = new Map()
|
||||
const assignments = new Map()
|
||||
function visit(node) {
|
||||
if (
|
||||
ts.isBinaryExpression(node) &&
|
||||
ts.isIdentifier(node.left) &&
|
||||
node.operatorToken.kind >= ts.SyntaxKind.FirstAssignment &&
|
||||
node.operatorToken.kind <= ts.SyntaxKind.LastAssignment
|
||||
) {
|
||||
const values = assignments.get(node.left.text) ?? []
|
||||
values.push(node.right)
|
||||
assignments.set(node.left.text, values)
|
||||
}
|
||||
if (ts.isImportDeclaration(node) && ts.isStringLiteral(node.moduleSpecifier)) {
|
||||
const target = resolveImport(root, rel, node.moduleSpecifier.text)
|
||||
const bindings = node.importClause?.namedBindings
|
||||
if (target && bindings && ts.isNamedImports(bindings)) {
|
||||
for (const binding of bindings.elements) {
|
||||
imports.set(binding.name.text, {
|
||||
rel: target,
|
||||
name: binding.propertyName?.text ?? binding.name.text
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
if (
|
||||
(ts.isFunctionDeclaration(node) || ts.isMethodDeclaration(node)) &&
|
||||
node.name &&
|
||||
node.body
|
||||
) {
|
||||
functions.set(node.name.text, node)
|
||||
}
|
||||
if (ts.isVariableDeclaration(node) && ts.isIdentifier(node.name) && node.initializer) {
|
||||
aliases.set(node.name.text, node.initializer)
|
||||
if (ts.isArrowFunction(node.initializer) || ts.isFunctionExpression(node.initializer)) {
|
||||
functions.set(node.name.text, node.initializer)
|
||||
}
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(source)
|
||||
return { source, imports, functions, aliases, assignments }
|
||||
}
|
||||
|
||||
export function collectParkingOwnershipViolations(root = process.cwd()) {
|
||||
const modules = new Map()
|
||||
const pending = [...ROOTS].flatMap(([rel, names]) =>
|
||||
names.map((name) => ({ rel, name, tainted: new Set() }))
|
||||
)
|
||||
for (const { rel, name, inputs } of OWNER_ROOTS) {
|
||||
pending.push({ rel: RENDERER + rel, name, tainted: new Set(inputs) })
|
||||
}
|
||||
const visited = new Set()
|
||||
const violations = new Set()
|
||||
while (pending.length) {
|
||||
const { rel, name, tainted } = pending.pop()
|
||||
if (STORE_BOUNDARIES.has(rel) || EFFECT_BOUNDARIES.has(`${rel}#${name}`)) {
|
||||
continue
|
||||
}
|
||||
const identity = `${rel}#${name}#${[...tainted].sort().join(',')}`
|
||||
if (visited.has(identity)) {
|
||||
continue
|
||||
}
|
||||
visited.add(identity)
|
||||
let mod = modules.get(rel)
|
||||
if (!mod) {
|
||||
modules.set(rel, (mod = readModule(root, rel)))
|
||||
}
|
||||
const fn = mod.functions.get(name)
|
||||
if (!fn) {
|
||||
continue
|
||||
}
|
||||
function hotMap(node, seen = new Set()) {
|
||||
if (ts.isPropertyAccessExpression(node)) {
|
||||
if (HOT_MAPS.has(node.name.text)) {
|
||||
return true
|
||||
}
|
||||
if (ts.isIdentifier(node.expression)) {
|
||||
const value = mod.aliases.get(node.expression.text)
|
||||
if (value && ts.isObjectLiteralExpression(value)) {
|
||||
const property = value.properties.find(
|
||||
(candidate) =>
|
||||
ts.isPropertyAssignment(candidate) &&
|
||||
candidate.name.getText(mod.source) === node.name.text
|
||||
)
|
||||
if (property && ts.isPropertyAssignment(property)) {
|
||||
return hotMap(property.initializer, seen)
|
||||
}
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
if (ts.isElementAccessExpression(node)) {
|
||||
return (
|
||||
ts.isStringLiteral(node.argumentExpression) && HOT_MAPS.has(node.argumentExpression.text)
|
||||
)
|
||||
}
|
||||
if (ts.isIdentifier(node)) {
|
||||
if (HOT_MAPS.has(node.text) || tainted.has(node.text)) {
|
||||
return true
|
||||
}
|
||||
if (seen.has(node.text)) {
|
||||
return false
|
||||
}
|
||||
seen.add(node.text)
|
||||
const alias = mod.aliases.get(node.text)
|
||||
return alias ? hotMap(alias, seen) : false
|
||||
}
|
||||
if (
|
||||
ts.isParenthesizedExpression(node) ||
|
||||
ts.isAsExpression(node) ||
|
||||
ts.isNonNullExpression(node)
|
||||
) {
|
||||
return hotMap(node.expression, seen)
|
||||
}
|
||||
if (
|
||||
ts.isBinaryExpression(node) &&
|
||||
node.operatorToken.kind === ts.SyntaxKind.QuestionQuestionToken
|
||||
) {
|
||||
return hotMap(node.left, seen)
|
||||
}
|
||||
return false
|
||||
}
|
||||
function report(node) {
|
||||
const line = mod.source.getLineAndCharacterOfPosition(node.getStart(mod.source)).line + 1
|
||||
violations.add(
|
||||
`${rel}:${line}: ${name} enumerates a whole parking input; use the addressed owner or a named source resync.`
|
||||
)
|
||||
}
|
||||
function visit(node) {
|
||||
if (
|
||||
ts.isFunctionDeclaration(node) &&
|
||||
node.name &&
|
||||
EFFECT_BOUNDARIES.has(`${rel}#${node.name.text}`)
|
||||
) {
|
||||
return
|
||||
}
|
||||
if (ts.isForInStatement(node) && hotMap(node.expression)) {
|
||||
report(node)
|
||||
}
|
||||
if (ts.isCallExpression(node)) {
|
||||
const callee = node.expression
|
||||
if (
|
||||
ts.isPropertyAccessExpression(callee) &&
|
||||
ts.isIdentifier(callee.expression) &&
|
||||
callee.expression.text === 'Object' &&
|
||||
ENUMERATORS.has(callee.name.text) &&
|
||||
node.arguments.some((arg) => hotMap(arg)) &&
|
||||
!(callee.name.text === 'keys' && KEY_DIFFS.has(`${rel}#${name}`)) &&
|
||||
!COLD_RESYNCS.has(`${rel}#${name}`)
|
||||
) {
|
||||
report(node)
|
||||
}
|
||||
if (ts.isIdentifier(callee)) {
|
||||
const target = mod.imports.get(callee.text) ?? { rel, name: callee.text }
|
||||
if (
|
||||
COLD_RESYNCS.has(`${target.rel}#${target.name}`) &&
|
||||
!isColdResyncCall(node, mod.source)
|
||||
) {
|
||||
report(node)
|
||||
}
|
||||
if (!STORE_BOUNDARIES.has(target.rel)) {
|
||||
let targetModule = modules.get(target.rel)
|
||||
if (!targetModule) {
|
||||
modules.set(target.rel, (targetModule = readModule(root, target.rel)))
|
||||
}
|
||||
const called = targetModule.functions.get(target.name)
|
||||
const parameters = new Set()
|
||||
called?.parameters.forEach((parameter, index) => {
|
||||
if (
|
||||
ts.isIdentifier(parameter.name) &&
|
||||
node.arguments[index] &&
|
||||
hotMap(node.arguments[index])
|
||||
) {
|
||||
parameters.add(parameter.name.text)
|
||||
}
|
||||
})
|
||||
if (called) {
|
||||
pending.push({ ...target, tainted: parameters })
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
ts.forEachChild(node, visit)
|
||||
}
|
||||
visit(fn.body)
|
||||
}
|
||||
return [...violations].sort()
|
||||
}
|
||||
|
||||
function collectPublicCoverageViolations(root) {
|
||||
const rel = `${WATCHERS}parked-terminal-tab-coverage.ts`
|
||||
const { source } = readModule(root, rel)
|
||||
const privateNames = new Set([
|
||||
'fallbackParkedPaneCandidates',
|
||||
'resolveParkedTerminalPaneCandidates',
|
||||
'capturedCoversFallback'
|
||||
])
|
||||
const violations = []
|
||||
for (const statement of source.statements) {
|
||||
const exported =
|
||||
ts.canHaveModifiers(statement) &&
|
||||
ts.getModifiers(statement)?.some((modifier) => modifier.kind === ts.SyntaxKind.ExportKeyword)
|
||||
const leaksDeclaration =
|
||||
exported && ts.isFunctionDeclaration(statement) && privateNames.has(statement.name?.text)
|
||||
const leaksNamedExport =
|
||||
ts.isExportDeclaration(statement) &&
|
||||
statement.exportClause &&
|
||||
ts.isNamedExports(statement.exportClause) &&
|
||||
statement.exportClause.elements.some((element) =>
|
||||
privateNames.has(element.propertyName?.text ?? element.name.text)
|
||||
)
|
||||
if (leaksDeclaration || leaksNamedExport) {
|
||||
violations.push(`${rel}: raw coverage derivation must stay private to its owner.`)
|
||||
}
|
||||
}
|
||||
return violations
|
||||
}
|
||||
|
||||
export function main(root = process.cwd()) {
|
||||
const violations = [
|
||||
...collectParkingOwnershipViolations(root),
|
||||
...collectUnaddressedWrites(root),
|
||||
...collectPublicCoverageViolations(root)
|
||||
]
|
||||
for (const violation of violations) {
|
||||
console.error(violation)
|
||||
}
|
||||
if (violations.length) {
|
||||
return 1
|
||||
}
|
||||
console.log(
|
||||
'terminal-parking-ownership: addressed consumer paths contain no whole input enumeration'
|
||||
)
|
||||
return 0
|
||||
}
|
||||
|
||||
if (process.argv[1] && import.meta.url === pathToFileURL(process.argv[1]).href) {
|
||||
process.exitCode = main()
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
import { TestRunner } from 'vitest'
|
||||
|
||||
export default class SharedWorkerSetupRunner extends TestRunner {
|
||||
importFile(filepath, source) {
|
||||
if (source === 'setup') {
|
||||
// Warm transforms can key setup roots by a different URL than Vitest invalidates.
|
||||
const modules = this.moduleRunner.evaluatedModules
|
||||
for (const node of modules.getModulesByFile(filepath) ?? []) {
|
||||
if (node.evaluated) {
|
||||
modules.invalidateModule(node)
|
||||
}
|
||||
}
|
||||
}
|
||||
return super.importFile(filepath, source)
|
||||
}
|
||||
}
|
||||
@@ -27,8 +27,6 @@ const NODE_RUNTIME_INCLUDE = [
|
||||
'src/main/browser/extensions/native-messaging/browser-extension-native-host-process-backpressure.test.ts',
|
||||
'src/main/daemon/providers/lifecycle/testing/daemon-init-provider-installation.test.ts',
|
||||
'src/renderer/src/components/terminal-pane/pty-transport/input/pty-input-write-queue.test.ts',
|
||||
'src/renderer/src/lib/react-commit-cascade-observer.test.ts',
|
||||
'src/renderer/src/lib/react-commit-cascade-telemetry.test.ts',
|
||||
// Asserts payloads are collected; Bun's GC scans the stack conservatively and may keep one alive.
|
||||
'src/shared/ws-inbound-message-queue.test.ts',
|
||||
'src/renderer/src/lib/agent-session/history/title-sync/ai-vault-tab-title-sync-inputs.test.ts',
|
||||
@@ -36,6 +34,7 @@ const NODE_RUNTIME_INCLUDE = [
|
||||
// Asserts an observer survives a forced collection; conservative retention would hide a lost one.
|
||||
'config/scripts/test-runtime/dom/happy-dom-mutation-observer-retention.test.ts',
|
||||
// These reach Node SQLite through a shared helper or a dynamic import, which the scan skips.
|
||||
'src/main/agent-hooks/server/testing/providers/codex/server-codex-session-start.test.ts',
|
||||
'src/main/claude/claude-transcript-catch-up.test.ts',
|
||||
'src/main/claude/claude-transcript-duration.test.ts',
|
||||
'tests/e2e/native-chat-startup-option-pickers.unit.test.ts',
|
||||
@@ -136,7 +135,7 @@ const NODE_RUNTIME_INCLUDE = [
|
||||
'src/main/gitlab/gitlab-known-host-retirement.test.ts',
|
||||
'src/main/window/main-window-updater-deferred-setup.test.ts',
|
||||
'src/renderer/src/components/terminal-pane/host-state/terminal-pane-host-state-memo.test.ts',
|
||||
'src/renderer/src/components/automations/use-automation-runs-dashboard-payload.test.tsx',
|
||||
'src/renderer/src/components/automations/runs/use-automation-runs-dashboard-payload.test.tsx',
|
||||
'src/main/native-chat/agent-session-journal/**/*.test.ts',
|
||||
'src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-terminal-writer-acquire.test.ts',
|
||||
'src/main/runtime/agent-session/records/agent-session-conversation-name-store.test.ts',
|
||||
@@ -168,7 +167,14 @@ const NODE_RUNTIME_INCLUDE = [
|
||||
'src/main/claude/claude-agent-sdk-contract-pins.test.ts',
|
||||
'config/scripts/orcad-distribution/server-bundle/profile-state-worker-smoke.test.mjs',
|
||||
'config/scripts/desktop-distribution/runtime-verification/process-host-dev-rebuild.test.ts',
|
||||
'config/scripts/test-runtime/node-worker/vitest-node-runtime-pool.test.ts'
|
||||
'config/scripts/test-runtime/node-worker/vitest-node-runtime-pool.test.ts',
|
||||
// Reopen WAL-backed row caches read-only, which Bun on macOS cannot.
|
||||
'src/main/agent-hooks/server/testing/identity/server-hook-session-binding.test.ts',
|
||||
'tests/e2e/helpers/persisted-profile-state.unit.test.ts',
|
||||
'src/main/runtime/push/notifications/mobile-notification-dismissal-store.test.ts',
|
||||
'src/main/runtime/push/notifications/mobile-notification-dismissal-read-failure.test.ts',
|
||||
'src/main/ipc/notifications-subject-retirement.test.ts',
|
||||
'src/main/ipc/notifications-external-acknowledgement.test.ts'
|
||||
]
|
||||
|
||||
/** `filters` limits the SQLite import scan to the tests a filtered CLI run can select. */
|
||||
|
||||
@@ -25,7 +25,7 @@ const LAYOUT_ORACLE_PREFIXES = [
|
||||
'src/renderer/src/store/workspace-layout/workspace-layout-cache',
|
||||
'src/renderer/src/components/terminal-pane/',
|
||||
'src/renderer/src/components/agent-session-continuation/AgentSessionContinuationMenuItem.tsx',
|
||||
'src/renderer/src/components/orchestration-crew/WorkerAutoCloseBanner.tsx',
|
||||
'src/renderer/src/components/terminal-pane/worker-lifetime/WorkerAutoCloseBanner.tsx',
|
||||
'src/renderer/src/attention/orca-window-foreground-focus.ts',
|
||||
'src/renderer/src/attention/notification-workspace-labels.ts',
|
||||
'src/renderer/src/lib/agent-session/identity/pane-agent-session-id.ts',
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
[
|
||||
{
|
||||
"filePath": "src/main/startup/main-process-quit.ts",
|
||||
"kind": "object-property:message",
|
||||
"text": "before-quit allowed for update install",
|
||||
"dynamic": false,
|
||||
"count": 1,
|
||||
"reason": "Updater lifecycle diagnostics are not displayed as UI copy."
|
||||
},
|
||||
{
|
||||
"filePath": "src/main/startup/main-process-quit.ts",
|
||||
"kind": "object-property:message",
|
||||
"text": "will-quit cleanup for update install; daemonTeardown=disconnect",
|
||||
"dynamic": false,
|
||||
"count": 1,
|
||||
"reason": "Updater lifecycle diagnostics are not displayed as UI copy."
|
||||
},
|
||||
{
|
||||
"filePath": "src/main/startup/profile-state-recovery-preflight.ts",
|
||||
"kind": "object-property:message",
|
||||
"text": "Invalid profile-state recovery launch.",
|
||||
"dynamic": false,
|
||||
"count": 1,
|
||||
"reason": "Existing recovery detail is user-visible and remains untranslated; tracked in issue 32207."
|
||||
}
|
||||
]
|
||||
@@ -23,8 +23,7 @@
|
||||
"../src/cli/runtime/runtime-access-denied.ts",
|
||||
"../src/cli/runtime/runtime-pid-liveness.ts",
|
||||
"../src/renderer/src/store/slices/worktrees/create/worktree-create-payload.ts",
|
||||
"../src/renderer/src/lib/orca-hook-trust.ts",
|
||||
"../src/renderer/src/lib/sha256.ts",
|
||||
"../src/renderer/src/runtime/repo-hooks/orca-hook-trust.ts",
|
||||
"../src/renderer/src/components/native-chat/native-chat-resolution-receipt.ts",
|
||||
"../src/renderer/src/components/native-chat/structured-agent-question-projection.ts",
|
||||
"../src/renderer/src/components/native-chat/subagents/native-chat-subagent-delegation.ts",
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
"exclude": [
|
||||
"../src/renderer/src/lib/agent-session/launch/new-tab/launch-agent-in-new-tab-main-surface.test.ts",
|
||||
"../src/renderer/src/components/task-page/linear/task-page-linear-detail-query.test.tsx",
|
||||
"../tests/e2e/terminal-agent-pane-launch.unit.test.ts",
|
||||
"../src/renderer/src/runtime/provider-accounts/observations/provider-account-observation.test-fixture.ts",
|
||||
"../src/shared/**/*.test.ts",
|
||||
"../src/shared/**/*.test.tsx",
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
"../src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail.test.ts",
|
||||
"../src/main/runtime/rpc/methods/orchestration/orchestration-check-ambiguous-caller.test.ts",
|
||||
"../src/renderer/src/components/task-page/linear/task-page-linear-detail-query.test.tsx",
|
||||
"../tests/e2e/terminal-agent-pane-launch.unit.test.ts",
|
||||
"../src/renderer/src/runtime/observed-provider-accounts.test.tsx",
|
||||
"../src/renderer/src/components/status-bar/ClaudeSwitcherMenu.observation.test.tsx",
|
||||
"../src/renderer/src/runtime/provider-accounts/observations/provider-account-observation.test-fixture.ts",
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
"exclude": [
|
||||
"../src/renderer/src/lib/agent-session/launch/new-tab/launch-agent-in-new-tab-main-surface.test.ts",
|
||||
"../src/renderer/src/components/task-page/linear/task-page-linear-detail-query.test.tsx",
|
||||
"../tests/e2e/terminal-agent-pane-launch.unit.test.ts",
|
||||
"../src/renderer/src/runtime/provider-accounts/observations/provider-account-observation.test-fixture.ts"
|
||||
],
|
||||
"compilerOptions": {
|
||||
|
||||
@@ -126,10 +126,12 @@ const bunProject = {
|
||||
}
|
||||
// Files whose state the per-file reset can undo share one worker's module cache instead of
|
||||
// re-importing thousands of modules each. ORCA_VITEST_ISOLATE_EVERY_FILE=1 turns it off.
|
||||
// Windows workers that keep native addons (process tree, ConPTY) across files die of heap
|
||||
// corruption (0xC0000374); production code loads them lazily, so the file scan can't see them.
|
||||
const runtimeProject = process.versions.bun ? bunProject : nodeProject
|
||||
const nodeRuntimeFiles = new Set(nodeRuntimeInclude.map((file) => file.replaceAll('\\', '/')))
|
||||
const sharedWorkerFiles =
|
||||
process.env.ORCA_VITEST_ISOLATE_EVERY_FILE === '1'
|
||||
process.env.ORCA_VITEST_ISOLATE_EVERY_FILE === '1' || process.platform === 'win32'
|
||||
? []
|
||||
: filesSafeToShareWorker(
|
||||
process.cwd(),
|
||||
@@ -151,6 +153,9 @@ const sharedProjects =
|
||||
name: `${runtimeProject.test.name}-shared`,
|
||||
include: sharedWorkerFiles,
|
||||
isolate: false,
|
||||
runner: resolve(
|
||||
'config/scripts/test-runtime/execution-policy/vitest-shared-worker-setup-runner.mjs'
|
||||
),
|
||||
setupFiles: [
|
||||
...runtimeProject.test.setupFiles,
|
||||
resolve('config/scripts/test-runtime/environment/vitest-shared-worker-file-reset.mjs')
|
||||
|
||||
@@ -6,7 +6,6 @@ import { nodeRuntimePool } from './scripts/test-runtime/node-worker/vitest-node-
|
||||
|
||||
const contracts = [
|
||||
'src/main/runtime/session-tabs/session-tabs-phone-layout-moves.test.ts',
|
||||
'src/renderer/src/components/terminal-pane/pty-connection/startup/saved-resume-cancellation.test.ts',
|
||||
'src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-terminal-writer-acquire.test.ts',
|
||||
'src/shared/agent-launch/permissions/tui-agent-permission-choice.test.ts',
|
||||
'src/main/runtime/rpc/methods/projects/repo.test.ts',
|
||||
@@ -18,12 +17,10 @@ const contracts = [
|
||||
'src/main/codex-usage/scanner-incremental-append.test.ts',
|
||||
'src/main/usage/jsonl-file-reader.test.ts',
|
||||
'src/main/usage/jsonl-file-snapshot.test.ts',
|
||||
'src/renderer/src/lib/pane-manager/pane-terminal-output-scheduler-queue-retention.test.ts',
|
||||
'config/scripts/static-analysis/oxlint-contracts/app-store-performance-plugin.test.mjs',
|
||||
'config/scripts/static-analysis/oxlint-contracts/quadratic-buffer-concat-plugin.test.mjs',
|
||||
'src/main/claude-usage/scanner-incremental-append.test.ts',
|
||||
'src/main/claude-usage/store-checkpoint-persistence.test.ts',
|
||||
'src/renderer/src/components/native-chat/surfaces/integration/NativeChatResolvedView.streaming-input.test.tsx'
|
||||
'src/main/claude-usage/store-checkpoint-persistence.test.ts'
|
||||
]
|
||||
for (const contract of contracts) {
|
||||
if (!existsSync(resolve(contract))) {
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
4 src/renderer/src/components/dashboard/build-dashboard-bucket-counts.ts # P5b-2 must clear: optional state fields; memo compare goes stale when absent
|
||||
3 src/renderer/src/components/dashboard/dashboard-card-terminal-input.ts # P5b-2 must clear: optional state fields default to empty
|
||||
1 src/renderer/src/components/dashboard/dashboard-snapshot-workspaces.ts # P5b-2 must clear: optional state field defaults to empty
|
||||
1 src/renderer/src/components/dashboard/dashboard-worktree-launch-options.ts # P5b-2 must clear: optional state field defaults to empty
|
||||
4 src/renderer/src/components/dashboard/useDashboardPopoutBridge.ts # P5b-2 must clear: change detection on optional fields never fires when absent
|
||||
2 src/renderer/src/components/dashboard/useRetainedAgents.ts # reads a passed-in copy
|
||||
1 src/renderer/src/components/editor/markdown/documents/markdown-document-worktree-path-selector.ts # P5b-2 must clear: optional state field
|
||||
@@ -22,7 +21,7 @@
|
||||
1 src/renderer/src/components/sidebar/worktree-list/navigation/pending-reveal-inputs.ts # reads a passed-in copy
|
||||
1 src/renderer/src/components/sidebar/worktree-list/navigation/use-pending-reveal.ts # reads a passed-in copy
|
||||
2 src/renderer/src/components/sidebar/worktree-list/viewport/VirtualizedWorktreeViewport.tsx # reads a passed-in copy
|
||||
2 src/renderer/src/components/skills/skill-install-workspace-choices.ts # reads a passed-in copy
|
||||
2 src/renderer/src/components/skills/installation/skill-install-workspace-choices.ts # reads a passed-in copy
|
||||
1 src/renderer/src/components/terminal-pane/links/files/terminal-worktree-path-link.ts # P5b-2 must clear: loosely typed state param
|
||||
1 src/renderer/src/components/workspace-space/space-window-state.ts # reads a passed-in copy
|
||||
1 src/renderer/src/hooks/composer-state/composer-source-state.ts # P5b-2 must clear: composer store snapshot
|
||||
@@ -36,10 +35,10 @@
|
||||
1 src/renderer/src/runtime/hosts/wsl/local-project-runtime-workspace.ts # P5b-2 must clear: optional state field defaults to empty
|
||||
1 src/renderer/src/lib/resolved-worktree-execution-host.ts # P5b-2 must clear: loosely typed state param
|
||||
2 src/renderer/src/lib/workspace/ownership/runtime-session-mirror-owners.ts # P5b-2 must clear: optional state fields default to empty
|
||||
2 src/renderer/src/lib/terminal-worktree-route.ts # P5b-2 must clear: the unattributed-twin check reads both catalogs directly
|
||||
2 src/renderer/src/lib/workspace/ownership/terminal-worktree-route.ts # P5b-2 must clear: the unattributed-twin check reads both catalogs directly
|
||||
3 src/renderer/src/lib/typing-latency/diagnostic-summary.ts # P5b-2 must clear: optional state field
|
||||
2 src/renderer/src/lib/unread-badge-count.ts # reads a passed-in copy
|
||||
1 src/renderer/src/lib/workspace-directory.ts # P5b-2 must clear: optional state field defaults to empty
|
||||
1 src/renderer/src/lib/workspace/paths/workspace-directory.ts # P5b-2 must clear: optional state field defaults to empty
|
||||
2 src/renderer/src/lib/workspace/ownership/workspace-terminal-host-authority.ts # P5b-2 must clear: optional state fields
|
||||
1 src/renderer/src/lib/workspace/activation/initial-surface/worktree-initial-terminal-seeding.ts # P5b-2 must clear: treats an undefined field as a narrow adapter
|
||||
1 src/renderer/src/lib/workspace/activation/worktree-activation-pty-inventory.ts # P5b-2 must clear: loosely typed state param
|
||||
|
||||
@@ -44,7 +44,7 @@ Tokens pair a **surface** with a **foreground** that meets contrast on it; alway
|
||||
- Body letter-spacing is set globally on `body`; don't override per component.
|
||||
- Use Tailwind's scale. Common: 14px body/default buttons, 13px sidebar items and dense rows, 12px sub-text and paths, 11px uppercase meta/captions.
|
||||
- Use `text-2xs` (11px) and `text-3xs` (10px), not `text-[11px]` / `text-[10px]`.
|
||||
- Category labels: 11px, `font-semibold`, `uppercase`, `tracking-wider` (0.05em).
|
||||
- Category labels: 11px, `font-semibold`, `uppercase`, `tracking-wider` (0.05em). Settings content uses sentence case without tracking: 14px row labels, `text-settings-detail` (12.5px) help, and `text-settings-heading` (15px) semibold section headings. Settings form rows use about 9px vertical padding (44px minimum), selects are 28px, and the centered content column is at most 720px with at least 32px side gutters. These density rules are scoped to `.settings-view-shell`; shared primitives retain their defaults elsewhere.
|
||||
- Native chat has its own lint-enforced scale and colours: see [native-chat.md](./styleguide/native-chat.md).
|
||||
|
||||
## Radius and elevation
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="113" height="20" role="img" aria-label="downloads: 162m">
|
||||
<title>downloads: 162m</title>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="113" height="20" role="img" aria-label="downloads: 168m">
|
||||
<title>downloads: 168m</title>
|
||||
<linearGradient id="s" x2="0" y2="100%">
|
||||
<stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
|
||||
<stop offset="1" stop-opacity=".1"/>
|
||||
@@ -15,7 +15,7 @@
|
||||
<g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="11">
|
||||
<text x="37" y="15" fill="#010101" fill-opacity=".3">downloads</text>
|
||||
<text x="37" y="14">downloads</text>
|
||||
<text x="93.5" y="15" fill="#010101" fill-opacity=".3">162m</text>
|
||||
<text x="93.5" y="14">162m</text>
|
||||
<text x="93.5" y="15" fill="#010101" fill-opacity=".3">168m</text>
|
||||
<text x="93.5" y="14">168m</text>
|
||||
</g>
|
||||
</svg>
|
||||
|
||||
|
Before Width: | Height: | Size: 943 B After Width: | Height: | Size: 943 B |
|
Before Width: | Height: | Size: 462 KiB After Width: | Height: | Size: 473 KiB |
|
Before Width: | Height: | Size: 392 KiB |
|
Before Width: | Height: | Size: 400 KiB |
|
Before Width: | Height: | Size: 391 KiB |
|
Before Width: | Height: | Size: 385 KiB |
|
Before Width: | Height: | Size: 381 KiB |
|
Before Width: | Height: | Size: 386 KiB After Width: | Height: | Size: 395 KiB |
@@ -0,0 +1,57 @@
|
||||
# Orca Development Environment
|
||||
|
||||
Setup details beyond [`CONTRIBUTING.md`](../.github/CONTRIBUTING.md).
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Install Node 24, the pnpm version in `packageManager` in [`package.json`](../package.json), and the Bun version in [`config/.bun-version`](../config/.bun-version).
|
||||
|
||||
The server, its workers, and its packaged dependencies target Node 24. The compatibility launcher and CLI still target Node 18; the launcher hands off to bundled Node 24 before loading server code. WSL guest programs and host discovery retain their Node 18 minimum. Keep Node 24 APIs and server imports out of these host compatibility paths. Running an unpackaged server directly requires Node 24 or newer.
|
||||
|
||||
`corepack enable` needs Corepack 0.34.5 or newer (`npm install -g corepack@latest`). On Windows it fails with `EPERM` outside an elevated shell when Node is in `C:\Program Files\nodejs`; run `npm install -g pnpm@<that version>` instead.
|
||||
|
||||
`pnpm install` compiles native modules such as `node-pty`, so a fresh machine also needs:
|
||||
|
||||
- **macOS**: Xcode Command Line Tools (`xcode-select --install`).
|
||||
- **Windows**: Python 3 and Visual Studio Build Tools with the "Desktop development with C++" workload.
|
||||
- **Linux**: a C++ toolchain, Python 3, Electron's libraries, and `xvfb` (used by `*.electron.test.ts` when `DISPLAY` is unset). On Ubuntu 24.04+ and Debian 13+ (older releases name the last package `libasound2`):
|
||||
|
||||
```bash
|
||||
sudo apt-get update && sudo apt-get install -y build-essential python3 xvfb libgtk-3-0 libnss3 libgbm1 libasound2t64
|
||||
```
|
||||
|
||||
Re-run `pnpm -C mobile install --frozen-lockfile` whenever `mobile/pnpm-lock.yaml` changes.
|
||||
|
||||
## Dev Profiles and Parallel Instances
|
||||
|
||||
`pnpm dev` in a linked Git worktree uses its own profile, renderer port (from 15200), and CDP port (from 9333), so worktrees run side by side. The main checkout uses the shared `orca-dev` profile. The chosen profile and ports are printed on an `ORCA_DEV_INSTANCE` line and written to `out/dev-instance.json`.
|
||||
|
||||
| Option | Effect |
|
||||
| ----------------------------------------------------------------------- | ---------------------------------------------------------- |
|
||||
| `pnpm dev --shared-profile` or `ORCA_DEV_PROFILE=shared` | Use the shared `orca-dev` profile |
|
||||
| `pnpm dev --worktree-profile` or `ORCA_DEV_PROFILE=worktree` | Use a per-worktree profile, including in the main checkout |
|
||||
| `ORCA_DEV_USER_DATA_PATH=<dir>` | Use an explicit profile directory |
|
||||
| `REMOTE_DEBUGGING_PORT=<port>`, `ORCA_DEV_RENDERER_PORT=<port>` | Pin a port |
|
||||
| `pnpm dev --seed-profile[=<dir>]` or `ORCA_DEV_SEED_PROFILE=<dir or 1>` | Seed an empty profile on first launch |
|
||||
|
||||
After a worktree is removed and no process still uses its profile, a later `pnpm dev` can automatically delete that profile and its saved state. Back up any state you need before removing the worktree; the `userData` field in `ORCA_DEV_INSTANCE` or `out/dev-instance.json` gives the profile directory.
|
||||
|
||||
Seeding copies projects, workspaces, settings, SSH targets, and the Orca account session from another profile (default `orca-dev`, else the installed app's). Seed from `orca-dev` if you need to stay signed in: dev builds cannot decrypt secrets the installed app encrypted.
|
||||
|
||||
```bash
|
||||
pnpm dev:seed-profile [--from=<profile dir>] [--to=<profile dir>] [--reset]
|
||||
pnpm dev:fresh [--keep] [--seed-from[=<profile dir>]] # temporary profile, removed on exit
|
||||
```
|
||||
|
||||
## Installs and Builds
|
||||
|
||||
- Local installs use pnpm's global virtual store (`~/pnpm/store`) shared by all worktrees. Do not keep a `node_modules` in your home directory: it hides missing-dependency bugs. Set `ORCA_PNPM_GLOBAL_VIRTUAL_STORE=0` in your shell to opt out.
|
||||
- Before a cross-architecture build (including `pnpm build:mac`, which builds x64 and arm64), run `pnpm install:release`.
|
||||
- On Linux, `pnpm build`, `pnpm build:native`, and packaging need a running Docker daemon for the clipboard helper. For native Wayland development, run `pnpm build:native` before `pnpm dev`. See the [clipboard build guide](../native/wayland-clipboard/README.md#building-and-testing).
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
- Slow main-process rebuilds: set `ORCA_DEV_MAIN_SOURCEMAPS=0` before `pnpm dev` when you don't need main-process source maps.
|
||||
- Renderer misbehaving in dev: set `ORCA_DEV_BUNDLED=0` to turn off bundled dev mode, and report it.
|
||||
- Test passes alone but fails after others: add `// @orca-isolated-worker` to the file; `ORCA_VITEST_ISOLATE_EVERY_FILE=1` isolates every file to confirm a leak. Windows always isolates every file, because native addons kept across files corrupt the heap.
|
||||
- Slow typechecks: where supported, `pnpm tc` keeps incremental caches in `.cache/typecheck/`; delete it to force a fresh check.
|
||||
@@ -249,11 +249,9 @@ Associez-la à l'app de bureau pour surveiller et piloter vos agents depuis votr
|
||||
|
||||
- **Discord :** Rejoignez la communauté sur **[Discord](https://discord.gg/fzjDKHxv8Q)**.
|
||||
- **Twitter / X :** Suivez **[@orca_build](https://x.com/orca_build)** pour les news et annonces.
|
||||
- **WeChat :** Scannez pour rejoindre un groupe WeChat de la communauté Orca. Si un groupe est complet, rejoignez-en un autre.
|
||||
- **WeChat :** Scannez pour rejoindre un groupe WeChat de la communauté Orca.
|
||||
|
||||
<img src="../assets/wechat-qr-group14.jpg" alt="QR code du groupe WeChat de la communauté Orca" width="160" />
|
||||
<img src="../assets/wechat-qr-group15.jpg" alt="QR code du groupe WeChat de la communauté Orca" width="160" />
|
||||
<img src="../assets/wechat-qr-group16.jpg" alt="QR code du groupe WeChat de la communauté Orca" width="160" />
|
||||
<img src="../assets/wechat-qr.jpg" alt="QR code du groupe WeChat de la communauté Orca" width="160" />
|
||||
|
||||
- **Feedback & idées :** On ship vite. Il manque quelque chose ? [Demandez une feature](https://github.com/stablyai/orca/issues).
|
||||
- **Confidentialité :** Voir la [doc confidentialité & télémétrie](https://www.onorca.dev/docs/telemetry) pour ce qu'Orca collecte en anonyme et comment désactiver la télémétrie.
|
||||
|
||||
@@ -244,11 +244,9 @@ yay -S stably-orca-bin
|
||||
|
||||
- **Discord:** **[Discord](https://discord.gg/fzjDKHxv8Q)** 커뮤니티에 참여하세요.
|
||||
- **Twitter / X:** 업데이트와 공지는 **[@orca_build](https://x.com/orca_build)** 를 팔로우하세요.
|
||||
- **WeChat:** QR 코드를 스캔해 Orca 커뮤니티 WeChat 그룹에 참여하세요. 한 그룹이 가득 찼다면 다른 그룹에 참여하세요.
|
||||
- **WeChat:** QR 코드를 스캔해 Orca 커뮤니티 WeChat 그룹에 참여하세요.
|
||||
|
||||
<img src="../assets/wechat-qr-group14.jpg" alt="Orca 커뮤니티 WeChat 그룹 QR 코드" width="160" />
|
||||
<img src="../assets/wechat-qr-group15.jpg" alt="Orca 커뮤니티 WeChat 그룹 QR 코드" width="160" />
|
||||
<img src="../assets/wechat-qr-group16.jpg" alt="Orca 커뮤니티 WeChat 그룹 QR 코드" width="160" />
|
||||
<img src="../assets/wechat-qr.jpg" alt="Orca 커뮤니티 WeChat 그룹 QR 코드" width="160" />
|
||||
|
||||
- **피드백과 아이디어:** 우리는 빠르게 출시합니다. 필요한 기능이 있나요? [새 기능을 요청](https://github.com/stablyai/orca/issues)하세요.
|
||||
- **개인정보 보호:** Orca가 수집하는 익명 사용 데이터와 수집 거부 방법은 [개인정보 및 텔레메트리 문서](https://www.onorca.dev/docs/telemetry)를 참고하세요.
|
||||
|
||||
@@ -245,11 +245,9 @@ yay -S stably-orca-bin
|
||||
|
||||
- **Discord:** Присоединяйтесь к сообществу в **[Discord](https://discord.gg/fzjDKHxv8Q)**.
|
||||
- **Twitter / X:** Подпишитесь на **[@orca_build](https://x.com/orca_build)**, чтобы узнавать об обновлениях и анонсах.
|
||||
- **WeChat:** Отсканируйте QR-код, чтобы присоединиться к группе сообщества Orca в WeChat. Если одна группа заполнена, присоединяйтесь к другой.
|
||||
- **WeChat:** Отсканируйте QR-код, чтобы присоединиться к группе сообщества Orca в WeChat.
|
||||
|
||||
<img src="../assets/wechat-qr-group14.jpg" alt="QR-код группы сообщества Orca в WeChat" width="160" />
|
||||
<img src="../assets/wechat-qr-group15.jpg" alt="QR-код группы сообщества Orca в WeChat" width="160" />
|
||||
<img src="../assets/wechat-qr-group16.jpg" alt="QR-код группы сообщества Orca в WeChat" width="160" />
|
||||
<img src="../assets/wechat-qr.jpg" alt="QR-код группы сообщества Orca в WeChat" width="160" />
|
||||
|
||||
- **Отзывы и идеи:** Мы быстро выпускаем обновления. Чего-то не хватает? [Предложите новую возможность](https://github.com/stablyai/orca/issues).
|
||||
- **Конфиденциальность:** В [документации о конфиденциальности и телеметрии](https://www.onorca.dev/docs/telemetry) описано, какие анонимные данные об использовании собирает Orca и как отказаться от их сбора.
|
||||
|
||||
@@ -242,11 +242,9 @@ Ajanlarınızı telefonunuzdan izlemek ve yönlendirmek için masaüstü uygulam
|
||||
|
||||
- **Discord:** Topluluğa **[Discord](https://discord.gg/fzjDKHxv8Q)** üzerinden katılın.
|
||||
- **Twitter / X:** Güncellemeler ve duyurular için **[@orca_build](https://x.com/orca_build)** hesabını takip edin.
|
||||
- **WeChat:** Orca topluluğunun bir WeChat grubuna katılmak için karekodu okutun. Bir grup doluysa başka bir gruba katılabilirsiniz.
|
||||
- **WeChat:** Orca topluluğunun bir WeChat grubuna katılmak için karekodu okutun.
|
||||
|
||||
<img src="../assets/wechat-qr-group14.jpg" alt="Orca topluluğunun WeChat grubu karekodu" width="160" />
|
||||
<img src="../assets/wechat-qr-group15.jpg" alt="Orca topluluğunun WeChat grubu karekodu" width="160" />
|
||||
<img src="../assets/wechat-qr-group16.jpg" alt="Orca topluluğunun WeChat grubu karekodu" width="160" />
|
||||
<img src="../assets/wechat-qr.jpg" alt="Orca topluluğunun WeChat grubu karekodu" width="160" />
|
||||
|
||||
- **Geri bildirim ve fikirler:** Hızlı sürüm çıkarıyoruz. Eksik bulduğunuz bir şey mi var? [Yeni bir özellik isteyin](https://github.com/stablyai/orca/issues).
|
||||
- **Gizlilik:** Orca'nın hangi anonim kullanım verisini topladığını ve bunu nasıl kapatacağınızı [gizlilik ve telemetri dokümanlarında](https://www.onorca.dev/docs/telemetry) bulabilirsiniz.
|
||||
|
||||
@@ -242,11 +242,9 @@ yay -S stably-orca-bin
|
||||
|
||||
- **Discord:** 加入 **[Discord](https://discord.gg/fzjDKHxv8Q)** 社区。
|
||||
- **Twitter / X:** 关注 **[@orca_build](https://x.com/orca_build)** 获取更新和公告。
|
||||
- **微信:** 扫码加入 Orca 社区微信群。如果一个群已满,可以加入其他群。
|
||||
- **微信:** 扫码加入 Orca 社区微信群。
|
||||
|
||||
<img src="../assets/wechat-qr-group14.jpg" alt="Orca 社区微信群二维码" width="160" />
|
||||
<img src="../assets/wechat-qr-group15.jpg" alt="Orca 社区微信群二维码" width="160" />
|
||||
<img src="../assets/wechat-qr-group16.jpg" alt="Orca 社区微信群二维码" width="160" />
|
||||
<img src="../assets/wechat-qr.jpg" alt="Orca 社区微信群二维码" width="160" />
|
||||
|
||||
- **反馈与想法:** 我们发布很快。缺少什么功能?[提交功能请求](https://github.com/stablyai/orca/issues)。
|
||||
- **隐私:** 查看[隐私与遥测文档](https://www.onorca.dev/docs/telemetry),了解 Orca 收集哪些匿名使用数据以及如何退出。
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<!-- Generated by `pnpm generate:plugin-schemas` from src/shared/plugins. Do not edit. -->
|
||||
|
||||
Host API 1.5 (`"pluginApi": 1`). Workers call a method with `await orca.host.call(name, params)`; panels and custom editors call the same methods through `window.orca.host.call(name, params)`. Each method lists the surfaces allowed to call it; any other surface gets `not_permitted`. `orca.host.has(name)` answers synchronously whether this Orca offers a method on the current surface, and `orca.api` is `{ major, minor }`. See [Plugin authoring](./plugin-authoring.md) for the frame API.
|
||||
Host API 1.6 (`"pluginApi": 1`). Workers call a method with `await orca.host.call(name, params)`; panels and custom editors call the same methods through `window.orca.host.call(name, params)`. Each method lists the surfaces allowed to call it; any other surface gets `not_permitted`. `orca.host.has(name)` answers synchronously whether this Orca offers a method on the current surface, and `orca.api` is `{ major, minor }`. See [Plugin authoring](./plugin-authoring.md) for the frame API.
|
||||
|
||||
Every call is checked against the capabilities the user approved, and params are validated before Orca runs anything: params are strict, so a field this Orca does not know is refused with `invalid_params` instead of being dropped. Mutations are recorded in the audit log as `plugin:<publisher>.<id>`.
|
||||
|
||||
@@ -29,7 +29,7 @@ Methods whose capability is `none` need no capability but still need the plugin
|
||||
| [`files.saveAs`](#filessaveas) | none | panel, editor | yes | 1.1 | Offers data (a string or ArrayBuffer, up to 64 MiB) in Orca's save dialog; the plugin never learns the path. Needs a click or key press in the frame; desktop app only. |
|
||||
| [`plugin.request`](#pluginrequest) | none | panel, editor | no | 1.2 | Asks the plugin's own worker to run the handler it registered with `orca.panels.handle(name)`, starting the worker if needed; resolves with what the handler returned. `unknown_method` when no handler has that name. |
|
||||
| [`agents.list`](#agentslist) | `agent:read` | worker, panel, editor | no | 1.2 | The agents in the focused workspace: their terminal, title, agent kind and status. `agent.status.changed` reports each change after. |
|
||||
| [`events.subscribe`](#eventssubscribe) | none | panel, editor | no | 1.2 | Delivers a workspace or agent event to this panel as `orca.on(event)`; needs the event's read capability. The frame APIs call it for you. |
|
||||
| [`events.subscribe`](#eventssubscribe) | none | panel, editor | no | 1.2 | Delivers a workspace, agent or editor event to this panel as `orca.on(event)`; needs the event's read capability, when it has one. The frame APIs call it for you. |
|
||||
| [`statusBar.update`](#statusbarupdate) | none | worker | no | 1.2 | Changes one of the plugin's `contributes.statusBarItems` (named by `id`): fields given replace their current value, `visible: false` hides it. Desktop app only; lasts until Orca restarts, and is hidden while the plugin is disabled. A plugin with `main` and status bar items has its worker started when it is enabled and kept running while it stays enabled, so a worker can poll and update its items without an event or a hook. |
|
||||
| [`appearance.read`](#appearanceread) | `appearance:write` | worker | no | 1.4 | Reads the current desktop appearance revision for a conditional update. |
|
||||
| [`appearance.apply`](#appearanceapply) | `appearance:write` | worker | yes | 1.4 | Publishes owned app/editor and terminal colors and selects them in the desktop. Returns publication, not renderer acknowledgement. |
|
||||
@@ -41,6 +41,7 @@ Methods whose capability is `none` need no capability but still need the plugin
|
||||
| [`agent.launch`](#agentlaunch) | `agent:launch` | worker | yes | 1.3 | Starts an agent's CLI in a new terminal of a workspace, in the background, and returns as soon as it starts; a `prompt` is sent once the agent is ready. |
|
||||
| [`editor.open`](#editoropen) | `workspace:write` | worker | yes | 1.3 | Opens a file of a workspace in an editor tab of Orca's window; desktop app only. `workspace.open` shows the workspace. |
|
||||
| [`commands.run`](#commandsrun) | `workspace:write` | worker | yes | 1.3 | Runs one of Orca's built-in actions in its window, never a plugin's replacement of it; desktop app only. |
|
||||
| [`editor.readTypography`](#editorreadtypography) | none | worker, panel, editor | no | 1.6 | The font family, size, weight, line height, ligatures, word wrap and minimap Orca's file editor uses now, editor zoom included. `editor.typography.changed` reports each change after. |
|
||||
|
||||
### `workspace.readContext`
|
||||
|
||||
@@ -180,10 +181,10 @@ The agents in the focused workspace: their terminal, title, agent kind and statu
|
||||
|
||||
### `events.subscribe`
|
||||
|
||||
Delivers a workspace or agent event to this panel as `orca.on(event)`; needs the event's read capability. The frame APIs call it for you.
|
||||
Delivers a workspace, agent or editor event to this panel as `orca.on(event)`; needs the event's read capability, when it has one. The frame APIs call it for you.
|
||||
|
||||
```ts
|
||||
(params: { event: "workspace.created" | "workspace.removed" | "agent.status.changed" | "workspace.changed" }) => { ok: true }
|
||||
(params: { event: "workspace.created" | "workspace.removed" | "agent.status.changed" | "workspace.changed" | "editor.typography.changed" }) => { ok: true }
|
||||
```
|
||||
|
||||
### `statusBar.update`
|
||||
@@ -274,9 +275,17 @@ Runs one of Orca's built-in actions in its window, never a plugin's replacement
|
||||
(params: { action: "worktree.history.back" | "worktree.history.forward" | "sidebar.left.toggle" | "sidebar.sleepingWorkspaces.toggle" | "floatingWorkspace.maximize" | "tab.rename" | "workspace.rename" | "workspace.openBoard" | "view.tasks" | "sidebar.right.toggle" | "sidebar.explorer.toggle" | "sidebar.search.toggle" | "sidebar.sourceControl.toggle" | "sidebar.checks.toggle" | "sidebar.ports.toggle" }) => { ran: true }
|
||||
```
|
||||
|
||||
### `editor.readTypography`
|
||||
|
||||
The font family, size, weight, line height, ligatures, word wrap and minimap Orca's file editor uses now, editor zoom included. `editor.typography.changed` reports each change after.
|
||||
|
||||
```ts
|
||||
(params?: {}) => { fontFamily: string; cssFontFamily: string; fontSize: number; fontWeight: string; lineHeight: number; fontLigatures: boolean; wordWrap: "on" | "off"; minimap: boolean }
|
||||
```
|
||||
|
||||
## Events
|
||||
|
||||
A worker receives the events its manifest lists in `contributes.events` through `orca.events.on(event, handler)`, which returns `{ dispose() }`. Each needs `main`, the `trusted-worker` profile and its domain's capability (`workspace:read` or `agent:read`). `orca plugin types` writes the payloads as `PluginEvents` in `orca/host`.
|
||||
A worker receives the events its manifest lists in `contributes.events` through `orca.events.on(event, handler)`, which returns `{ dispose() }`. Each needs `main`, the `trusted-worker` profile and its domain's capability (`workspace:read` or `agent:read`; editor events need none). `orca plugin types` writes the payloads as `PluginEvents` in `orca/host`.
|
||||
|
||||
| Event | Payload | Summary |
|
||||
| --- | --- | --- |
|
||||
@@ -284,6 +293,7 @@ A worker receives the events its manifest lists in `contributes.events` through
|
||||
| `workspace.removed` | `{ workspaceId: string; kind: "worktree" \| "folder"; path: string }` | A worktree workspace was removed. |
|
||||
| `agent.status.changed` | `{ workspaceId: string \| null; paneKey: string; terminalId?: string; title?: string; state: "working" \| "blocked" \| "waiting" \| "done"; receivedAt: number; mainAgent?: { state: "working" \| "blocked" \| "waiting" \| "done"; outcome?: "success" \| "failure" \| "cancellation" \| "superseded" \| "interruption" \| "unconfirmed"; stateStartedAt: number } }` | An agent in a terminal pane changed status; `workspaceId` is null when Orca cannot tie the pane to a workspace, and `terminalId` names its terminal when Orca lists it. |
|
||||
| `workspace.changed` | `{ context: { branch: string; displayName: string; terminals: { id: string; title?: string }[] } \| null }` | The focused workspace changed, or its terminals were opened, closed or renamed; `context` is what `workspace.readContext` now answers. Each new subscriber first gets the current context. |
|
||||
| `editor.typography.changed` | `{ fontFamily: string; cssFontFamily: string; fontSize: number; fontWeight: string; lineHeight: number; fontLigatures: boolean; wordWrap: "on" \| "off"; minimap: boolean }` | What Orca's file editor uses changed (a setting or the editor zoom); the payload is what `editor.readTypography` now answers. Needs no capability. |
|
||||
|
||||
## Hooks
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ Add `"$schema": "https://raw.githubusercontent.com/stablyai/orca/main/docs/schem
|
||||
| `contributes` | object | no | 1.4.160 | What the plugin adds to Orca. Every point defaults to empty. |
|
||||
| `contributes.panels` | [PanelContribution](#panelcontribution)[] | no | 1.4.160 | Sidebar panels. At most 64. |
|
||||
| `contributes.commands` | [CommandContribution](#commandcontribution)[] | no | 1.4.160 | Command palette entries. At most 256. |
|
||||
| `contributes.events` | [EventContribution](#eventcontribution)[] | no | 1.4.160 | Events delivered to the plugin worker. At most 4. |
|
||||
| `contributes.events` | [EventContribution](#eventcontribution)[] | no | 1.4.160 | Events delivered to the plugin worker. At most 5. |
|
||||
| `contributes.hooks` | [HookContribution](#hookcontribution)[] | no | 1.4.248 | Hooks the worker runs before or after Orca acts; Orca waits only on plugins that list one. At most 8. |
|
||||
| `contributes.languagePacks` | [LanguagePackContribution](#languagepackcontribution)[] | no | 1.4.160 | Interface translations. At most 16. |
|
||||
| `contributes.keybindings` | [KeybindingContribution](#keybindingcontribution)[] | no | 1.4.160 | Keyboard shortcuts for contributed commands. At most 256. |
|
||||
@@ -85,11 +85,11 @@ A command palette entry. Requires the `declarative` execution profile or higher.
|
||||
|
||||
## EventContribution
|
||||
|
||||
An event subscription. Requires `main`, the `trusted-worker` execution profile and the capability of the event's domain: `workspace:read` for workspace events, `agent:read` for agent events.
|
||||
An event subscription. Requires `main`, the `trusted-worker` execution profile and the capability of the event's domain: `workspace:read` for workspace events, `agent:read` for agent events. Editor events need no capability.
|
||||
|
||||
| Field | Type | Required | Since | Description |
|
||||
| --- | --- | --- | --- | --- |
|
||||
| `on` | `"workspace.created"` \| `"workspace.removed"` \| `"agent.status.changed"` \| `"workspace.changed"` | yes | 1.4.160 | Event delivered to the plugin worker. |
|
||||
| `on` | `"workspace.created"` \| `"workspace.removed"` \| `"agent.status.changed"` \| `"workspace.changed"` \| `"editor.typography.changed"` | yes | 1.4.160 | Event delivered to the plugin worker. |
|
||||
|
||||
## HookContribution
|
||||
|
||||
|
||||
@@ -208,9 +208,9 @@
|
||||
},
|
||||
"events": {
|
||||
"default": [],
|
||||
"description": "Events delivered to the plugin worker. At most 4.",
|
||||
"description": "Events delivered to the plugin worker. At most 5.",
|
||||
"x-orca-since": "1.4.160",
|
||||
"maxItems": 4,
|
||||
"maxItems": 5,
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/$defs/EventContribution"
|
||||
@@ -736,7 +736,8 @@
|
||||
"workspace.created",
|
||||
"workspace.removed",
|
||||
"agent.status.changed",
|
||||
"workspace.changed"
|
||||
"workspace.changed",
|
||||
"editor.typography.changed"
|
||||
],
|
||||
"description": "Event delivered to the plugin worker.",
|
||||
"x-orca-since": "1.4.160",
|
||||
@@ -744,7 +745,8 @@
|
||||
"workspace.created": "1.4.245",
|
||||
"workspace.removed": "1.4.245",
|
||||
"agent.status.changed": "1.4.160",
|
||||
"workspace.changed": "1.4.246"
|
||||
"workspace.changed": "1.4.246",
|
||||
"editor.typography.changed": "1.4.256"
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -752,7 +754,7 @@
|
||||
"on"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"description": "An event subscription. Requires `main`, the `trusted-worker` execution profile and the capability of the event's domain: `workspace:read` for workspace events, `agent:read` for agent events."
|
||||
"description": "An event subscription. Requires `main`, the `trusted-worker` execution profile and the capability of the event's domain: `workspace:read` for workspace events, `agent:read` for agent events. Editor events need no capability."
|
||||
},
|
||||
"HookContribution": {
|
||||
"type": "object",
|
||||
|
||||
@@ -27,4 +27,4 @@ The chat root (`.native-chat-appearance`) redefines these steps as ratios of the
|
||||
- **Focus rings:** full-width transcript rows use the inset ring (`focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring`) so it isn't clipped by the scroll container; standalone controls use `focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring`. Inside the chat `--ring` is `--chat-focus-ring`, which clears 3:1 on the canvas; don't lower its opacity.
|
||||
- **Theme overrides:** plugin themes can set `--chat-bold-foreground`, `--chat-muted-foreground`, `--chat-inline-code`, `--chat-inline-code-foreground`, `--chat-code-block`, `--chat-selection` and `--chat-selection-foreground`. They feed `text-chat-foreground-faint`, `bg-chat-inline-code-surface`, `bg-chat-code-surface` and the chat root's `::selection`, so use those rather than reading the theme tokens directly.
|
||||
- **Selection** inside the chat is the link hue mixed into the canvas (close to the system highlight), with selected text in the full foreground so every role stays 4.5:1. Don't add per-component `selection:` colors in transcript text.
|
||||
- **State colours:** warnings use `text-chat-warning`; diff lines use `text-chat-diff-added` / `text-chat-diff-removed`. They are mixed toward the foreground so they pass text contrast in light and dark. Don't use raw palette colours (`text-yellow-500`) or the git decoration tokens for text on a tinted row.
|
||||
- **State colours:** warnings use `text-chat-warning`; diff lines use `text-chat-diff-added` / `text-chat-diff-removed`; what the reader has not seen yet uses `text-chat-unread`. They are mixed toward the foreground so they pass text contrast in light and dark. Don't use raw palette colours (`text-yellow-500`) or the git decoration tokens for text on a tinted row.
|
||||
|
||||
@@ -114,6 +114,7 @@
|
||||
"./plugins/android-window-density.js",
|
||||
"./plugins/android-release-signing.js",
|
||||
"./plugins/android-navigation-bar-theme.js",
|
||||
"./plugins/android-device-transfer-rules.js",
|
||||
"./plugins/ios-pod-deployment-target-floor.js",
|
||||
"./plugins/ios-scene-lifecycle.js",
|
||||
"./plugins/ios-bundle-phase-quoted-script-path.js",
|
||||
|
||||
@@ -27,7 +27,7 @@ import {
|
||||
} from '../src/notifications/push-receive'
|
||||
import { startPushTokenSync } from '../src/notifications/push-registration'
|
||||
import { ensureDesktopNotificationChannel } from '../src/notifications/desktop-notification-channel'
|
||||
import { loadHostCatalog } from '../src/transport/hosts/host-store'
|
||||
import { loadHostCatalog } from '../src/host-catalog/host-store'
|
||||
import { usePairingLinks } from '../src/navigation/use-pairing-links'
|
||||
import { consumeInitialLaunchIntent } from '../src/navigation/initial-launch-intent'
|
||||
import { recoverMobileRelayPairing } from '../src/pairing/mobile-relay-pairing-recovery'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { useCallback, useEffect, useMemo, useState, useSyncExternalStore } from
|
||||
import { View, Text, Pressable } from 'react-native'
|
||||
import { useLocalSearchParams, useRouter } from 'expo-router'
|
||||
import * as Clipboard from 'expo-clipboard'
|
||||
import { loadHosts } from '../src/transport/hosts/host-store'
|
||||
import { loadHosts } from '../src/host-catalog/host-store'
|
||||
import { connectionLogStore } from '../src/diagnostics/connection/persisted-connection-log-store'
|
||||
import { useRpcClientContext } from '../src/transport/connection/client-context'
|
||||
import { useHostClient } from '../src/transport/connection/host-client-hooks'
|
||||
@@ -22,7 +22,7 @@ import { connectionDiagnosticsScreenStyles as styles } from '../src/diagnostics/
|
||||
import { useMobileColorScheme } from '../src/theme/use-mobile-color-scheme'
|
||||
import { NATIVE_APP_LOG_ID } from '../src/diagnostics/native-render-log'
|
||||
import type { ConnectionLogEntry } from '../src/diagnostics/connection/connection-log-types'
|
||||
import type { HostProfile } from '../src/transport/hosts/host-profile'
|
||||
import type { HostProfile } from '../src/host-catalog/host-profile'
|
||||
import { pressedStyle } from '../src/theme/mobile-theme'
|
||||
|
||||
// Keep empty snapshot identity stable or useSyncExternalStore rerenders forever.
|
||||
|
||||
@@ -18,7 +18,7 @@ import { NavBar } from '../../../src/components/nav-bar/NavBar'
|
||||
import { NavBarButton } from '../../../src/components/nav-bar/NavBarButton'
|
||||
import { themedStyleSheet } from '../../../src/theme/themed-styles'
|
||||
import { useMobileColorScheme } from '../../../src/theme/use-mobile-color-scheme'
|
||||
import { loadHosts, updateHostNameAndEndpoint } from '../../../src/transport/hosts/host-store'
|
||||
import { loadHosts, updateHostNameAndEndpoint } from '../../../src/host-catalog/host-store'
|
||||
import { displayHostEndpoint } from '../../../src/transport/hosts/host-endpoint'
|
||||
import { resolveHostEndpointEdit } from '../../../src/transport/hosts/host-endpoint-edit'
|
||||
import {
|
||||
@@ -26,12 +26,12 @@ import {
|
||||
usePrimeHosts,
|
||||
useRefreshHostClient
|
||||
} from '../../../src/transport/connection/host-client-hooks'
|
||||
import { removeHostAndCloseClient } from '../../../src/transport/hosts/host-removal-lifecycle'
|
||||
import { useHostDisplay } from '../../../src/transport/hosts/use-host-display'
|
||||
import { removeHostAndCloseClient } from '../../../src/host-catalog/host-removal-lifecycle'
|
||||
import { useHostDisplay } from '../../../src/host-descriptors/use-host-display'
|
||||
import { leaveHostRoute } from '../../../src/host-route-exit'
|
||||
import { ConfirmModal } from '../../../src/components/ConfirmModal'
|
||||
import { ListGroup, ListRow } from '../../../src/components/list/ListGroup'
|
||||
import type { HostProfile } from '../../../src/transport/hosts/host-profile'
|
||||
import type { HostProfile } from '../../../src/host-catalog/host-profile'
|
||||
import { hostOs } from '../../../src/platform/host-os'
|
||||
import { translate } from '../../../src/i18n/mobile-i18n'
|
||||
import { useMobileTranslation } from '../../../src/i18n/use-mobile-translation'
|
||||
|
||||
@@ -12,8 +12,8 @@ import { colors, spacing } from '../src/theme/mobile-theme'
|
||||
import { useMobileColorScheme } from '../src/theme/use-mobile-color-scheme'
|
||||
import type { Translate } from '../src/i18n/mobile-i18n'
|
||||
import { useMobileTranslation } from '../src/i18n/use-mobile-translation'
|
||||
import { loadHosts, peekHosts } from '../src/transport/hosts/host-store'
|
||||
import type { HostProfile } from '../src/transport/hosts/host-profile'
|
||||
import { loadHosts, peekHosts } from '../src/host-catalog/host-store'
|
||||
import type { HostProfile } from '../src/host-catalog/host-profile'
|
||||
import { useFocusedSettingsHostClients } from '../src/settings/settings-host-client-connections'
|
||||
import type { RpcClient } from '../src/transport/rpc/rpc-client-contract'
|
||||
import { LIST_LEADING_INSET, ListRow } from '../src/components/list/ListGroup'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useEffect, useMemo, useState } from 'react'
|
||||
import { useRouter } from 'expo-router'
|
||||
import { loadHosts, peekHosts } from '../src/transport/hosts/host-store'
|
||||
import type { HostProfile } from '../src/transport/hosts/host-profile'
|
||||
import { loadHosts, peekHosts } from '../src/host-catalog/host-store'
|
||||
import type { HostProfile } from '../src/host-catalog/host-profile'
|
||||
import { useFocusedSettingsHostClients } from '../src/settings/settings-host-client-connections'
|
||||
import VoiceSettingsScreen from '../src/settings/voice-settings-screen'
|
||||
import { nativeVoiceSettingsOperations } from '../src/settings/native-voice-settings-operations'
|
||||
|
||||
@@ -15,6 +15,8 @@ android {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// Android ships no brotli decoder; Google's pure-Java one, as okhttp-brotli uses.
|
||||
implementation 'org.brotli:dec:0.1.2'
|
||||
testImplementation 'junit:junit:4.13.2'
|
||||
// The android.jar used by JVM unit tests stubs org.json; the shared vectors are JSON.
|
||||
testImplementation 'org.json:json:20240303'
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
package expo.modules.orcagziputf8codec
|
||||
|
||||
import java.io.ByteArrayInputStream
|
||||
import java.io.IOException
|
||||
import org.brotli.dec.BrotliInputStream
|
||||
|
||||
class BoundedBrotliException(message: String) : Exception(message)
|
||||
|
||||
/** Inflate one brotli stream into at most outputLimit bytes; callers pass one byte beyond the length they
|
||||
* accept and check the result's length and hash, so truncated or overlong input fails there. */
|
||||
fun brotliDecompressBounded(input: ByteArray, outputLimit: Int): ByteArray {
|
||||
if (outputLimit <= 0 || input.isEmpty()) {
|
||||
throw BoundedBrotliException("nothing to inflate")
|
||||
}
|
||||
val output = ByteArray(outputLimit)
|
||||
var produced = 0
|
||||
try {
|
||||
BrotliInputStream(ByteArrayInputStream(input)).use { stream ->
|
||||
while (produced < outputLimit) {
|
||||
val count = stream.read(output, produced, outputLimit - produced)
|
||||
if (count < 0) {
|
||||
break
|
||||
}
|
||||
produced += count
|
||||
}
|
||||
}
|
||||
} catch (error: IOException) {
|
||||
throw BoundedBrotliException(error.message ?: "invalid brotli data")
|
||||
}
|
||||
return if (produced == outputLimit) output else output.copyOf(produced)
|
||||
}
|
||||
@@ -15,5 +15,10 @@ class OrcaGzipUtf8CodecModule : Module() {
|
||||
Function("decodeUtf8") { input: ByteArray ->
|
||||
decodeStrictUtf8(input)
|
||||
}
|
||||
|
||||
// Async: a whole bundle asset can take tens of ms, too long to hold the JS thread.
|
||||
AsyncFunction("brotliDecompress") { input: ByteArray, outputLimit: Int ->
|
||||
brotliDecompressBounded(input, outputLimit)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
import Compression
|
||||
import Foundation
|
||||
|
||||
struct BoundedBrotliError: Error, CustomStringConvertible {
|
||||
let description: String
|
||||
}
|
||||
|
||||
/// Inflate one brotli stream into at most outputLimit bytes; callers pass one byte beyond the length they
|
||||
/// accept and check the result's length and hash. Compression returns nothing for a stream that is invalid,
|
||||
/// truncated or longer than the buffer, so all three throw here.
|
||||
func brotliDecompressBounded(_ input: Data, outputLimit: Int) throws -> Data {
|
||||
guard outputLimit > 0, !input.isEmpty else {
|
||||
throw BoundedBrotliError(description: "nothing to inflate")
|
||||
}
|
||||
var output = Data(count: outputLimit)
|
||||
let produced = input.withUnsafeBytes { (inBytes: UnsafeRawBufferPointer) -> Int in
|
||||
output.withUnsafeMutableBytes { (outBytes: UnsafeMutableRawBufferPointer) -> Int in
|
||||
compression_decode_buffer(
|
||||
outBytes.bindMemory(to: UInt8.self).baseAddress!, outputLimit,
|
||||
inBytes.bindMemory(to: UInt8.self).baseAddress!, inBytes.count,
|
||||
nil, COMPRESSION_BROTLI)
|
||||
}
|
||||
}
|
||||
guard produced > 0 else {
|
||||
throw BoundedBrotliError(description: "not a whole brotli stream within the output limit")
|
||||
}
|
||||
return produced == outputLimit ? output : output.prefix(produced)
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
Pod::Spec.new do |s|
|
||||
s.name = 'OrcaGzipUtf8Codec'
|
||||
s.version = '0.0.1'
|
||||
s.summary = 'Bounded gunzip and strict UTF-8 decode'
|
||||
s.summary = 'Bounded gunzip and brotli inflate, and strict UTF-8 decode'
|
||||
s.description = s.summary
|
||||
s.license = { :type => 'MIT' }
|
||||
s.author = 'Orca'
|
||||
@@ -11,6 +11,6 @@ Pod::Spec.new do |s|
|
||||
s.swift_version = '5.9'
|
||||
s.static_framework = true
|
||||
s.dependency 'ExpoModulesCore'
|
||||
s.libraries = 'z'
|
||||
s.libraries = 'z', 'compression'
|
||||
s.source_files = '**/*.swift'
|
||||
end
|
||||
|
||||
@@ -12,5 +12,10 @@ public class OrcaGzipUtf8CodecModule: Module {
|
||||
Function("decodeUtf8") { (input: Data) -> String? in
|
||||
decodeStrictUtf8(input)
|
||||
}
|
||||
|
||||
// Async: a whole bundle asset can take tens of ms, too long to hold the JS thread.
|
||||
AsyncFunction("brotliDecompress") { (input: Data, outputLimit: Int) throws -> Data in
|
||||
try brotliDecompressBounded(input, outputLimit: outputLimit)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,6 +5,8 @@ export type OrcaGzipUtf8CodecModule = {
|
||||
gunzip(input: Uint8Array, outputLimit: number): Uint8Array
|
||||
/** Well-formed UTF-8 with no leading BOM, decoded; null otherwise. */
|
||||
decodeUtf8(input: Uint8Array): string | null
|
||||
/** Inflate one brotli stream into at most outputLimit bytes, off the JS thread; throws on bad input. */
|
||||
brotliDecompress(input: Uint8Array, outputLimit: number): Promise<Uint8Array<ArrayBuffer>>
|
||||
}
|
||||
|
||||
/** Null in a binary built before the module existed. */
|
||||
|
||||
@@ -13,6 +13,7 @@ import expo.modules.kotlin.exception.Exceptions
|
||||
import expo.modules.kotlin.functions.Queues
|
||||
import expo.modules.kotlin.modules.Module
|
||||
import expo.modules.kotlin.modules.ModuleDefinition
|
||||
import java.io.File
|
||||
|
||||
class OrcaMobileWebShellModule : Module() {
|
||||
private val main = Handler(Looper.getMainLooper())
|
||||
@@ -57,6 +58,16 @@ class OrcaMobileWebShellModule : Module() {
|
||||
discardSpare()
|
||||
}
|
||||
|
||||
// Page builds live in filesDir: "Clear cache", cleaner apps and low storage empty cacheDir, which cost a full
|
||||
// download on the next open. allowBackup false and the device-transfer rules keep them on this phone.
|
||||
Function("generationStoreDirectory") { name: String ->
|
||||
val filesDir = appContext.reactContext?.filesDir ?: throw Exceptions.ReactContextLost()
|
||||
val directory = File(filesDir, name)
|
||||
// A full disk can refuse the folder; the caller then keeps the old root.
|
||||
if (!directory.mkdirs() && !directory.isDirectory) throw UnableToCreateGenerationStoreException()
|
||||
Uri.fromFile(directory).toString()
|
||||
}
|
||||
|
||||
AsyncFunction("prepareSpareDocument") { directory: String, sessionId: String ->
|
||||
val activity = appContext.currentActivity ?: return@AsyncFunction false
|
||||
MobileWebShellSparePool.prepare(activity, directory, sessionId)
|
||||
@@ -124,3 +135,6 @@ class OrcaMobileWebShellModule : Module() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private class UnableToCreateGenerationStoreException :
|
||||
CodedException("The page build folder could not be created")
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
import Foundation
|
||||
|
||||
/// Application Support, which iOS never purges; the builds can be downloaded again, so backups skip them.
|
||||
enum MobileWebShellGenerationStoreDirectory {
|
||||
static func prepare(name: String) throws -> String {
|
||||
var directory = try FileManager.default
|
||||
.url(for: .applicationSupportDirectory, in: .userDomainMask, appropriateFor: nil, create: true)
|
||||
.appendingPathComponent(name, isDirectory: true)
|
||||
try FileManager.default.createDirectory(at: directory, withIntermediateDirectories: true)
|
||||
var values = URLResourceValues()
|
||||
values.isExcludedFromBackup = true
|
||||
try directory.setResourceValues(values)
|
||||
return directory.absoluteString
|
||||
}
|
||||
}
|
||||
@@ -47,6 +47,11 @@ public class OrcaMobileWebShellModule: Module {
|
||||
MobileWebShellSparePool.shared.discardAll()
|
||||
}.runOnQueue(.main)
|
||||
|
||||
// The generation store's root as a file URL, created and excluded from backups.
|
||||
Function("generationStoreDirectory") { (name: String) throws -> String in
|
||||
try MobileWebShellGenerationStoreDirectory.prepare(name: name)
|
||||
}
|
||||
|
||||
// Home calls this once it has a paired host, so a user with nothing to open pays nothing.
|
||||
Function("warmUp") {
|
||||
// A second's delay keeps the warm-up off the launch's first frames.
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
import { requireOptionalNativeModule } from 'expo-modules-core'
|
||||
|
||||
// <name> under the app's durable storage (iOS Application Support, outside backups; Android filesDir) as a file URL.
|
||||
// Null from a binary built before the function existed, or when the directory can't be made.
|
||||
export function generationStoreDirectory(name: string): string | null {
|
||||
const shell = requireOptionalNativeModule<{
|
||||
generationStoreDirectory?: (name: string) => string
|
||||
}>('OrcaMobileWebShell')
|
||||
try {
|
||||
return shell?.generationStoreDirectory?.(name) ?? null
|
||||
} catch {
|
||||
return null
|
||||
}
|
||||
}
|
||||