pi-ui-extend 1.0.41 → 1.0.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +50 -13
- package/dist/app/app.d.ts +13 -0
- package/dist/app/app.js +158 -8
- package/dist/app/cli/install.js +2 -2
- package/dist/app/commands/command-controller.d.ts +4 -0
- package/dist/app/commands/command-controller.js +11 -0
- package/dist/app/commands/command-git-actions.d.ts +25 -0
- package/dist/app/commands/command-git-actions.js +381 -0
- package/dist/app/commands/command-host.d.ts +4 -0
- package/dist/app/commands/command-host.js +5 -2
- package/dist/app/commands/command-model-actions.d.ts +1 -0
- package/dist/app/commands/command-model-actions.js +57 -35
- package/dist/app/commands/command-navigation-actions.d.ts +1 -0
- package/dist/app/commands/command-navigation-actions.js +16 -3
- package/dist/app/commands/command-registry.d.ts +2 -0
- package/dist/app/commands/command-registry.js +15 -1
- package/dist/app/commands/command-session-actions.js +9 -3
- package/dist/app/commands/reload-context-inventory.d.ts +11 -0
- package/dist/app/commands/reload-context-inventory.js +70 -0
- package/dist/app/extensions/extension-actions-controller.d.ts +1 -0
- package/dist/app/extensions/extension-actions-controller.js +6 -0
- package/dist/app/extensions/subagent-catalog-state.d.ts +9 -0
- package/dist/app/extensions/subagent-catalog-state.js +23 -0
- package/dist/app/input/autocomplete-controller.js +61 -34
- package/dist/app/input/input-action-controller.d.ts +2 -0
- package/dist/app/input/input-action-controller.js +8 -1
- package/dist/app/input/input-controller.d.ts +2 -1
- package/dist/app/input/input-controller.js +7 -2
- package/dist/app/input/prompt-enhancer-controller.js +53 -35
- package/dist/app/input/voice-controller.d.ts +41 -45
- package/dist/app/input/voice-controller.js +351 -419
- package/dist/app/model/model-usage-controller.js +17 -7
- package/dist/app/model/model-usage-status.d.ts +4 -1
- package/dist/app/model/model-usage-status.js +270 -46
- package/dist/app/popup/menu-items-controller.d.ts +13 -3
- package/dist/app/popup/menu-items-controller.js +37 -21
- package/dist/app/popup/popup-action-controller.d.ts +12 -2
- package/dist/app/popup/popup-action-controller.js +77 -24
- package/dist/app/popup/popup-menu-controller.d.ts +36 -14
- package/dist/app/popup/popup-menu-controller.js +239 -69
- package/dist/app/rendering/dcp-stats.d.ts +9 -4
- package/dist/app/rendering/dcp-stats.js +40 -425
- package/dist/app/rendering/editor-panels.js +10 -4
- package/dist/app/rendering/popup-menu-renderer.d.ts +3 -5
- package/dist/app/rendering/popup-menu-renderer.js +42 -37
- package/dist/app/rendering/render-controller.js +23 -2
- package/dist/app/rendering/status-line-renderer.d.ts +5 -0
- package/dist/app/rendering/status-line-renderer.js +41 -5
- package/dist/app/rendering/tab-line-renderer.js +26 -20
- package/dist/app/runtime.d.ts +12 -1
- package/dist/app/runtime.js +120 -12
- package/dist/app/screen/mouse-controller.d.ts +2 -0
- package/dist/app/screen/mouse-controller.js +17 -7
- package/dist/app/screen/status-controller.d.ts +4 -0
- package/dist/app/screen/status-controller.js +5 -0
- package/dist/app/session/lazy-session-manager.js +34 -0
- package/dist/app/session/session-event-controller.d.ts +1 -0
- package/dist/app/session/session-event-controller.js +10 -1
- package/dist/app/session/session-history.d.ts +1 -0
- package/dist/app/session/session-history.js +12 -1
- package/dist/app/session/session-lifecycle-controller.d.ts +7 -1
- package/dist/app/session/session-lifecycle-controller.js +16 -1
- package/dist/app/session/tabs-controller.d.ts +26 -1
- package/dist/app/session/tabs-controller.js +454 -147
- package/dist/app/subagents/subagents-files.js +60 -1
- package/dist/app/subagents/subagents-model.d.ts +1 -0
- package/dist/app/subagents/subagents-model.js +18 -2
- package/dist/app/subagents/subagents-widget-controller.d.ts +1 -0
- package/dist/app/subagents/subagents-widget-controller.js +6 -0
- package/dist/app/types.d.ts +16 -1
- package/dist/app/workspace/workspace-actions-controller.js +10 -2
- package/dist/app/workspace/workspace-undo.d.ts +1 -0
- package/dist/app/workspace/workspace-undo.js +1 -0
- package/dist/bundled-extensions/question/index.js +9 -1
- package/dist/bundled-extensions/question/remote.d.ts +4 -0
- package/dist/bundled-extensions/question/remote.js +33 -0
- package/dist/bundled-extensions/telegram-connector/bot.d.ts +43 -0
- package/dist/bundled-extensions/telegram-connector/bot.js +166 -0
- package/dist/bundled-extensions/telegram-connector/config.d.ts +8 -0
- package/dist/bundled-extensions/telegram-connector/config.js +87 -0
- package/dist/bundled-extensions/telegram-connector/coordinator.d.ts +66 -0
- package/dist/bundled-extensions/telegram-connector/coordinator.js +413 -0
- package/dist/bundled-extensions/telegram-connector/index.d.ts +3 -0
- package/dist/bundled-extensions/telegram-connector/index.js +195 -0
- package/dist/bundled-extensions/terminal-bell/index.d.ts +0 -8
- package/dist/bundled-extensions/terminal-bell/index.js +0 -76
- package/dist/bundled-extensions/workspace-undo/index.d.ts +26 -0
- package/dist/bundled-extensions/workspace-undo/index.js +191 -0
- package/dist/config.d.ts +21 -2
- package/dist/config.js +159 -32
- package/dist/default-pix-config.js +25 -5
- package/dist/schemas/index.d.ts +1 -0
- package/dist/schemas/index.js +1 -0
- package/dist/schemas/pi-tools-suite-schema.d.ts +88 -62
- package/dist/schemas/pi-tools-suite-schema.js +54 -83
- package/dist/schemas/pix-schema.d.ts +19 -2
- package/dist/schemas/pix-schema.js +47 -5
- package/dist/schemas/tasks-schema.d.ts +18 -0
- package/dist/schemas/tasks-schema.js +41 -0
- package/docs/concurrency.md +9 -1
- package/docs/desktop-mvp.md +22 -6
- package/docs/desktop-task-manager.md +148 -84
- package/docs/release.md +30 -6
- package/external/pi-tools-suite/README.md +197 -84
- package/external/pi-tools-suite/docs/evals.md +1 -1
- package/external/pi-tools-suite/docs/session-recovery.md +47 -14
- package/external/pi-tools-suite/docs/subagent-model-pools.md +48 -30
- package/external/pi-tools-suite/docs/ui-qa-subagent.md +440 -0
- package/external/pi-tools-suite/package.json +6 -1
- package/external/pi-tools-suite/src/antigravity-auth/auth-store.ts +2 -1
- package/external/pi-tools-suite/src/antigravity-auth/constants.ts +9 -3
- package/external/pi-tools-suite/src/antigravity-auth/headers.ts +41 -3
- package/external/pi-tools-suite/src/antigravity-auth/models.ts +94 -21
- package/external/pi-tools-suite/src/antigravity-auth/oauth.ts +5 -17
- package/external/pi-tools-suite/src/antigravity-auth/payload.ts +72 -7
- package/external/pi-tools-suite/src/antigravity-auth/stream.ts +13 -1
- package/external/pi-tools-suite/src/async-subagents/agents/frontier-review.md +23 -0
- package/external/pi-tools-suite/src/async-subagents/agents/implement.md +1 -1
- package/external/pi-tools-suite/src/async-subagents/agents/presets.jsonc +16 -0
- package/external/pi-tools-suite/src/async-subagents/agents/research.md +5 -3
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/backends/browser.mjs +346 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/backends/desktop.mjs +1038 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/backends/tui.mjs +759 -0
- package/external/pi-tools-suite/src/async-subagents/agents/{browser-qa → ui-qa/browser}/scripts/browser-qa-runner.mjs +32 -23
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/drivers/chrome-devtools/chrome-devtools-provider.mjs +895 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/drivers/linux/linux-atspi.py +494 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/drivers/macos/macos-accessibility.swift +1085 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/drivers/native-terminal/bridge-client.mjs +50 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/drivers/native-terminal/native-terminal-host.mjs +501 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/drivers/windows/windows-uia.ps1 +454 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/browser-auth.md +114 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/browser-chrome-devtools.md +91 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/browser-playwright.md +145 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/browser.md +82 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/desktop-linux.md +26 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/desktop-macos.md +29 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/desktop-windows.md +23 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/desktop.md +54 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/tui-native-terminal.md +59 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/tui-pty.md +37 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/tui.md +60 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/scripts/ui-qa-runner.mjs +535 -0
- package/external/pi-tools-suite/src/async-subagents/agents/ui-qa.md +75 -0
- package/external/pi-tools-suite/src/async-subagents/commands.ts +15 -71
- package/external/pi-tools-suite/src/async-subagents/core/activity.ts +33 -0
- package/external/pi-tools-suite/src/async-subagents/core/agent-catalog.ts +5 -4
- package/external/pi-tools-suite/src/async-subagents/core/agent-strategy.ts +1 -1
- package/external/pi-tools-suite/src/async-subagents/core/agents-dir.ts +8 -5
- package/external/pi-tools-suite/src/async-subagents/core/browser-qa.ts +16 -2
- package/external/pi-tools-suite/src/async-subagents/core/config.ts +160 -327
- package/external/pi-tools-suite/src/async-subagents/core/model-selection.ts +2 -1
- package/external/pi-tools-suite/src/async-subagents/core/registry.ts +158 -33
- package/external/pi-tools-suite/src/async-subagents/core/routing.ts +21 -5
- package/external/pi-tools-suite/src/async-subagents/core/spawn.ts +40 -26
- package/external/pi-tools-suite/src/async-subagents/core/state.ts +40 -0
- package/external/pi-tools-suite/src/async-subagents/core/types.ts +7 -0
- package/external/pi-tools-suite/src/async-subagents/core/ultrawork-auto.ts +51 -45
- package/external/pi-tools-suite/src/async-subagents/index.ts +69 -5
- package/external/pi-tools-suite/src/async-subagents/lib.ts +16 -9
- package/external/pi-tools-suite/src/async-subagents/tools/spawn.ts +8 -5
- package/external/pi-tools-suite/src/async-subagents/tools/subagents.ts +5 -4
- package/external/pi-tools-suite/src/async-subagents/types.ts +1 -0
- package/external/pi-tools-suite/src/coding-discipline/index.ts +90 -59
- package/external/pi-tools-suite/src/config.ts +55 -1
- package/external/pi-tools-suite/src/context-gateway/accounting-log.ts +282 -0
- package/external/pi-tools-suite/src/context-gateway/config.ts +77 -3
- package/external/pi-tools-suite/src/context-gateway/efficiency.ts +414 -0
- package/external/pi-tools-suite/src/context-gateway/enforcement.ts +222 -0
- package/external/pi-tools-suite/src/context-gateway/index.ts +206 -19
- package/external/pi-tools-suite/src/context-gateway/storeless-capabilities.ts +7 -7
- package/external/pi-tools-suite/src/context-gateway/telemetry.ts +101 -28
- package/external/pi-tools-suite/src/context-gateway/types.ts +16 -3
- package/external/pi-tools-suite/src/context-inventory.ts +99 -0
- package/external/pi-tools-suite/src/dcp/auto-compress-budget.ts +39 -4
- package/external/pi-tools-suite/src/dcp/auto-compress.ts +128 -49
- package/external/pi-tools-suite/src/dcp/commands.ts +32 -156
- package/external/pi-tools-suite/src/dcp/compress-tool.ts +177 -46
- package/external/pi-tools-suite/src/dcp/compression-blocks.ts +6 -58
- package/external/pi-tools-suite/src/dcp/compression-preview.ts +9 -0
- package/external/pi-tools-suite/src/dcp/compression-progress.ts +22 -0
- package/external/pi-tools-suite/src/dcp/config.ts +114 -17
- package/external/pi-tools-suite/src/dcp/conversation-index.ts +36 -9
- package/external/pi-tools-suite/src/dcp/diagnostics.ts +41 -0
- package/external/pi-tools-suite/src/dcp/fresh-tool-results.ts +38 -0
- package/external/pi-tools-suite/src/dcp/index.ts +338 -66
- package/external/pi-tools-suite/src/dcp/journal.ts +126 -4
- package/external/pi-tools-suite/src/dcp/progress-controller.ts +2 -1
- package/external/pi-tools-suite/src/dcp/prompts.ts +83 -192
- package/external/pi-tools-suite/src/dcp/protected-continuity.ts +175 -0
- package/external/pi-tools-suite/src/dcp/pruner-candidates.ts +93 -3
- package/external/pi-tools-suite/src/dcp/pruner-message-ids.ts +6 -10
- package/external/pi-tools-suite/src/dcp/pruner-nudge.ts +36 -33
- package/external/pi-tools-suite/src/dcp/pruner-tools.ts +6 -3
- package/external/pi-tools-suite/src/dcp/pruner.ts +1 -0
- package/external/pi-tools-suite/src/dcp/routine-pressure.ts +86 -0
- package/external/pi-tools-suite/src/dcp/state.ts +9 -0
- package/external/pi-tools-suite/src/dcp/statistics.d.ts +8 -0
- package/external/pi-tools-suite/src/dcp/statistics.js +156 -0
- package/external/pi-tools-suite/src/default-pi-tools-suite-config.ts +78 -22
- package/external/pi-tools-suite/src/index.ts +7 -1
- package/external/pi-tools-suite/src/lib/project.ts +36 -1
- package/external/pi-tools-suite/src/model-tools/index.ts +10 -7
- package/external/pi-tools-suite/src/repo-discovery/index.ts +304 -4
- package/external/pi-tools-suite/src/resource-registry/index.ts +2551 -0
- package/external/pi-tools-suite/src/session-recovery/index.ts +17 -0
- package/external/pi-tools-suite/src/shell-command-policy.ts +219 -0
- package/external/pi-tools-suite/src/todo/index.ts +21 -0
- package/external/pi-tools-suite/src/todo/todo.ts +19 -1
- package/external/pi-tools-suite/src/tool-descriptions.ts +47 -19
- package/package.json +10 -9
- package/schemas/pi-tools-suite.json +466 -287
- package/schemas/pix.json +129 -11
- package/schemas/tasks.json +131 -0
- package/skills/simplify/SKILL.md +33 -5
- package/docs/desktop-markdown-media.md +0 -77
- package/external/pi-tools-suite/docs/browser-qa-subagent.md +0 -177
- package/external/pi-tools-suite/docs/dcp-emergency-current-turn.md +0 -102
- package/external/pi-tools-suite/src/async-subagents/agents/browser-qa.md +0 -598
- package/external/pi-tools-suite/src/async-subagents/async-subagents.sample.jsonc +0 -54
- package/external/pi-tools-suite/src/skill-installer/index.ts +0 -333
- package/skills/playwright-cli/SKILL.md +0 -420
- package/skills/playwright-cli/references/element-attributes.md +0 -23
- package/skills/playwright-cli/references/playwright-tests.md +0 -50
- package/skills/playwright-cli/references/request-mocking.md +0 -87
- package/skills/playwright-cli/references/running-code.md +0 -241
- package/skills/playwright-cli/references/session-management.md +0 -273
- package/skills/playwright-cli/references/spec-driven-testing.md +0 -311
- package/skills/playwright-cli/references/storage-state.md +0 -290
- package/skills/playwright-cli/references/test-generation.md +0 -142
- package/skills/playwright-cli/references/tracing.md +0 -154
- package/skills/playwright-cli/references/video-recording.md +0 -147
- package/skills/spec-lite/SKILL.md +0 -140
- /package/external/pi-tools-suite/src/async-subagents/agents/{browser-qa → ui-qa/browser}/examples/qa-auth.example.jsonc +0 -0
- /package/external/pi-tools-suite/src/async-subagents/agents/{browser-qa → ui-qa/browser}/examples/qa-flow.example.jsonc +0 -0
- /package/external/pi-tools-suite/src/async-subagents/agents/{browser-qa → ui-qa/browser}/vendor/fflate.LICENSE +0 -0
- /package/external/pi-tools-suite/src/async-subagents/agents/{browser-qa → ui-qa/browser}/vendor/fflate.mjs +0 -0
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
# Browser detail: Playwright
|
|
2
|
+
|
|
3
|
+
Load this topic only when the browser router or `selection.guide` selected
|
|
4
|
+
`playwright`. Browser probe/run still goes through `PI_UI_QA_RUNNER`; do not
|
|
5
|
+
invoke the bundled browser runner directly except for the explicit auth
|
|
6
|
+
metadata/scaffold commands documented by the `auth` guide.
|
|
7
|
+
|
|
8
|
+
## Target and authentication
|
|
9
|
+
|
|
10
|
+
Use `target.browserDriver: "playwright"` when the route must be explicit.
|
|
11
|
+
Supported target fields are `url`/`baseUrl`, exact `allowedOrigins`, optional
|
|
12
|
+
trusted `profile`, and `browserDriver`. Do not combine Playwright with
|
|
13
|
+
`target.devtools`.
|
|
14
|
+
|
|
15
|
+
If the requested verification requires authentication, first load:
|
|
16
|
+
|
|
17
|
+
```sh
|
|
18
|
+
node "$PI_UI_QA_RUNNER" guide --backend browser --topic auth
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Follow that guide for profile discovery/scaffolding. Never read, print, grep,
|
|
22
|
+
copy, or edit credential values from `.pi/qa_auth.jsonc`; the trusted runner
|
|
23
|
+
applies them internally. Put `authRejectedIf` directly after navigation or a
|
|
24
|
+
transition that may expose an expired session.
|
|
25
|
+
|
|
26
|
+
## Playwright flow surface
|
|
27
|
+
|
|
28
|
+
Supported actions:
|
|
29
|
+
|
|
30
|
+
- navigation/stability: `goto`, `reload`, `waitFor`, `waitForTimeout`;
|
|
31
|
+
- interaction: `click`, `doubleClick`, `hover`, `fill`, `press`, `check`,
|
|
32
|
+
`uncheck`, `selectOption`, `wheel`, safe `evaluate`, `dragTo`, `uploadFiles`,
|
|
33
|
+
`openPopup`, `download`;
|
|
34
|
+
- assertions: `assertVisible`, `assertHidden`, `assertEnabled`,
|
|
35
|
+
`assertDisabled`, `assertChecked`, `assertUnchecked`, `assertText`,
|
|
36
|
+
`assertTextContent`, `assertValue`, `assertAttribute`, `assertCount`,
|
|
37
|
+
`assertURL`, `assertDOMMetric`;
|
|
38
|
+
- evidence/auth: `screenshot`, `authRejectedIf`.
|
|
39
|
+
|
|
40
|
+
Locators accept exactly one primary selector from `testId`, `role` (optional
|
|
41
|
+
`name`), `label`, `placeholder`, `text`, or `css`; add `exact: true` when useful.
|
|
42
|
+
Prefer stable product contracts in that order, with CSS as a last resort.
|
|
43
|
+
String assertions require exactly one of `equals` or `includes`.
|
|
44
|
+
|
|
45
|
+
`assertText` uses visible rendered text; use `assertTextContent` only when raw
|
|
46
|
+
DOM text is intentionally the oracle. `assertAttribute` is appropriate for
|
|
47
|
+
observable `aria-*`, `data-*`, `href`, and similar state. Assertions retry
|
|
48
|
+
within the bounded flow timeout.
|
|
49
|
+
|
|
50
|
+
## Viewport and deterministic environment
|
|
51
|
+
|
|
52
|
+
Optional top-level `viewport` accepts integer `width`/`height` from `320×240`
|
|
53
|
+
through `3840×2160`; default is `1280×720`. The same dimensions drive recorded
|
|
54
|
+
video.
|
|
55
|
+
|
|
56
|
+
Optional top-level `environment` supports:
|
|
57
|
+
|
|
58
|
+
- `locale`;
|
|
59
|
+
- `timezoneId`;
|
|
60
|
+
- `colorScheme`: `light`, `dark`, or `no-preference`;
|
|
61
|
+
- `reducedMotion`: `reduce` or `no-preference`.
|
|
62
|
+
|
|
63
|
+
Defaults are deterministic: `en-US`, `UTC`, `light`, and `reduce`. Set these
|
|
64
|
+
explicitly when locale/timezone/theme/motion affects the behavior.
|
|
65
|
+
|
|
66
|
+
## Interaction and causal expectations
|
|
67
|
+
|
|
68
|
+
Visible interactions wait for document readiness, causally-started requests in
|
|
69
|
+
a bounded readiness window, common visible busy markers, and a short stable
|
|
70
|
+
recording interval. Prefer an assertion immediately after an action over an
|
|
71
|
+
arbitrary sleep. `waitForTimeout` is bounded and should be exceptional.
|
|
72
|
+
|
|
73
|
+
Triggering interactions may arm race-free expectations before input:
|
|
74
|
+
|
|
75
|
+
- `expectResponse`: exact origin-relative `path`, uppercase `method`, and
|
|
76
|
+
integer `status` 100..599;
|
|
77
|
+
- `expectDialog`: dialog `type`, a nested `message` matcher using exactly one of
|
|
78
|
+
`equals`/`includes`, and boolean `accept`.
|
|
79
|
+
|
|
80
|
+
The runner does not publish response bodies/headers/query URLs or actual dialog
|
|
81
|
+
text in diagnostics.
|
|
82
|
+
|
|
83
|
+
`dragTo` requires a source `locator` and `dropTarget`, with optional bounded
|
|
84
|
+
relative source/drop positions. Do not emulate unsupported drag protocols with
|
|
85
|
+
raw JavaScript.
|
|
86
|
+
|
|
87
|
+
`uploadFiles` is memory-only: entries are `{name,mimeType,base64}`, up to 10
|
|
88
|
+
files, 5 MiB each and 10 MiB total. Filesystem paths/directories are unsupported;
|
|
89
|
+
an empty list clears the file input.
|
|
90
|
+
|
|
91
|
+
`download` atomically clicks and validates a nested safe filename matcher.
|
|
92
|
+
`maxBytes` defaults to 5 MiB and is capped at 25 MiB. Retain bytes only when
|
|
93
|
+
needed as evidence; retained downloads use runner-generated private names and
|
|
94
|
+
are scanned for configured authentication before publication.
|
|
95
|
+
|
|
96
|
+
## Frames, popups, scrolling, and safe evaluate
|
|
97
|
+
|
|
98
|
+
`openPopup` captures a same-origin popup under a safe name (maximum three).
|
|
99
|
+
Later steps can target `{ "type": "popup", "name": "..." }`. Same-origin
|
|
100
|
+
iframes use `{ "type": "frame", "locator": {...} }`, optionally inside a named
|
|
101
|
+
popup. Live origin is checked before scoped steps; cross-origin frames/popups
|
|
102
|
+
are rejected unless the provider contract explicitly supports them.
|
|
103
|
+
|
|
104
|
+
`wheel` accepts finite `deltaX`/`deltaY`, at least one non-zero. With a locator,
|
|
105
|
+
the runner hovers it before wheel input.
|
|
106
|
+
|
|
107
|
+
The `evaluate` action is not arbitrary JavaScript. Safe operations are:
|
|
108
|
+
|
|
109
|
+
- `scrollTo`: optional locator plus numeric `x`/`y` or `"max"`;
|
|
110
|
+
- `scrollBy`: optional locator plus numeric `deltaX`/`deltaY`;
|
|
111
|
+
- `metrics`: optional locator and safe name, returning bounded layout metrics.
|
|
112
|
+
|
|
113
|
+
Page/element metrics include scroll/client dimensions and positions. Use
|
|
114
|
+
`assertDOMMetric` with exactly one comparator (`equals`, `greaterThan`,
|
|
115
|
+
`greaterThanOrEqual`, `lessThan`, `lessThanOrEqual`) for pass/fail.
|
|
116
|
+
|
|
117
|
+
## Scenario design
|
|
118
|
+
|
|
119
|
+
Build the proof as setup -> smallest user action -> observable oracle. For a
|
|
120
|
+
fix verification, prefer one focused regression scenario rather than a tour.
|
|
121
|
+
Use semantic locators and state transitions; do not add timeouts merely to hide
|
|
122
|
+
races. A locator/setup error may justify fixing the flow, but an observed
|
|
123
|
+
product mismatch must remain a failure.
|
|
124
|
+
|
|
125
|
+
For responsive bugs, set the viewport and use DOM metrics when dimensions or
|
|
126
|
+
scroll state are part of the proof. For custom loaders not covered by the
|
|
127
|
+
runner's generic readiness model, explicitly wait/assert that loader state and
|
|
128
|
+
then assert loaded content.
|
|
129
|
+
|
|
130
|
+
## Evidence and cleanup
|
|
131
|
+
|
|
132
|
+
The trusted Playwright backend attempts final/failure screenshot, first-page
|
|
133
|
+
video, and sanitized post-auth trace; named `screenshot` steps should capture
|
|
134
|
+
only materially useful states. Popups can add separate videos. Pointer actions
|
|
135
|
+
may receive runner-owned visual annotations for chronology; those annotations
|
|
136
|
+
are evidence, never the oracle.
|
|
137
|
+
|
|
138
|
+
For authenticated form flows, password fields remain masked in video, but
|
|
139
|
+
visible login identifiers may appear; treat evidence as private. Tracing begins
|
|
140
|
+
only after login succeeds.
|
|
141
|
+
|
|
142
|
+
Each invocation owns an isolated context and private evidence directory and
|
|
143
|
+
closes resources in cleanup. Use separate runs for separate auth profiles. Do
|
|
144
|
+
not create a shared browser context, expose storage/cookies to the model, or
|
|
145
|
+
move backend evidence out of the agent-local workspace.
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
# Browser backend router
|
|
2
|
+
|
|
3
|
+
Load this guide only after the common UI-QA role classified the requested
|
|
4
|
+
surface as `browser`. Use only the unified `PI_UI_QA_RUNNER` for probe/run.
|
|
5
|
+
Provider-specific tools are runner implementation details and must not be
|
|
6
|
+
invoked directly by the QA child.
|
|
7
|
+
|
|
8
|
+
## Choose one detail route
|
|
9
|
+
|
|
10
|
+
Choose from the requested proof, never from a repository/app name:
|
|
11
|
+
|
|
12
|
+
- ordinary repeatable browser E2E, rich semantic/form locators, deterministic
|
|
13
|
+
browser environment, downloads, frames/popups, automatic video/trace, or
|
|
14
|
+
trusted QA authentication -> `playwright`;
|
|
15
|
+
- browser-runtime diagnostics such as accessibility-tree snapshots,
|
|
16
|
+
console/network assertions, Lighthouse, performance summaries, or memory
|
|
17
|
+
summaries -> `chrome-devtools`;
|
|
18
|
+
- authentication setup/update work -> load `auth` first, then use the
|
|
19
|
+
`playwright` detail guide for the verification flow.
|
|
20
|
+
|
|
21
|
+
Load only the needed topic:
|
|
22
|
+
|
|
23
|
+
```sh
|
|
24
|
+
node "$PI_UI_QA_RUNNER" guide --backend browser --topic playwright
|
|
25
|
+
node "$PI_UI_QA_RUNNER" guide --backend browser --topic chrome-devtools
|
|
26
|
+
node "$PI_UI_QA_RUNNER" guide --backend browser --topic auth
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
`target.browserDriver` accepts `"auto"`, `"playwright"`, or
|
|
30
|
+
`"chrome-devtools"`. Use `auto` when the flow itself makes the required
|
|
31
|
+
capability unambiguous. When you must load a detail guide before authoring its
|
|
32
|
+
provider-specific steps, explicitly set the matching driver for preflight.
|
|
33
|
+
`target.profile` is a trusted-auth input and therefore routes to Playwright.
|
|
34
|
+
|
|
35
|
+
After every completed-flow `probe`, `selection.guide` is authoritative. It must
|
|
36
|
+
be `{ "backend": "browser", "topic": <the detail guide you are following> }`
|
|
37
|
+
before `run`. If it differs, load that returned topic, fix the flow if needed,
|
|
38
|
+
and probe again. Never weaken the requested proof merely to fit another
|
|
39
|
+
provider.
|
|
40
|
+
|
|
41
|
+
## Common browser flow
|
|
42
|
+
|
|
43
|
+
The unified flow is declarative JSONC under
|
|
44
|
+
`$PI_SUBAGENT_AGENT_DIR/ui-qa/flows/`:
|
|
45
|
+
|
|
46
|
+
```jsonc
|
|
47
|
+
{
|
|
48
|
+
"version": 1,
|
|
49
|
+
"target": {
|
|
50
|
+
"url": "https://example.test/",
|
|
51
|
+
"browserDriver": "auto"
|
|
52
|
+
},
|
|
53
|
+
"steps": []
|
|
54
|
+
}
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
The target may use `url`/`baseUrl`, exact `allowedOrigins`, the selected
|
|
58
|
+
`browserDriver`, and provider-specific fields documented by the loaded detail
|
|
59
|
+
guide. Never put credentials, tokens, raw executable JavaScript, wildcard
|
|
60
|
+
origins, or inferred sibling domains in a flow. A profile id and target URL are
|
|
61
|
+
non-secret; credential values remain runner-owned.
|
|
62
|
+
|
|
63
|
+
Treat discovery as a short preflight. Identify the real requested URL, the
|
|
64
|
+
smallest user action that exercises the behavior, and a deterministic
|
|
65
|
+
product-visible postcondition. A successful click/navigation is not proof.
|
|
66
|
+
Verification uses one `run` per requested profile/variant; explicitly
|
|
67
|
+
exploratory QA may use at most three bounded runs with one hypothesis each.
|
|
68
|
+
|
|
69
|
+
Prefer state-based waits/assertions over sleeps. Preserve a product mismatch as
|
|
70
|
+
a failure rather than changing the oracle. Additional origins must be exact
|
|
71
|
+
`http(s)` origins explicitly justified by the requested scenario.
|
|
72
|
+
|
|
73
|
+
## Evidence and reporting
|
|
74
|
+
|
|
75
|
+
Report every artifact returned by the unified runner, including failed runs.
|
|
76
|
+
Inspect at least one meaningful screenshot with `read` before claiming visual
|
|
77
|
+
QA. Deterministic assertions determine PASS/FAIL; screenshots/video/traces
|
|
78
|
+
explain the result.
|
|
79
|
+
|
|
80
|
+
Let the runner own browser contexts/pages, provider processes, private evidence
|
|
81
|
+
directories, and cleanup. Do not create shared/default browser sessions outside
|
|
82
|
+
the runner or copy private QA evidence into a persistent shared directory.
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# Desktop detail: Linux AT-SPI
|
|
2
|
+
|
|
3
|
+
Load this topic only when `selection.guide.topic` is `linux-at-spi`.
|
|
4
|
+
|
|
5
|
+
The trusted bundled Python helper uses AT-SPI for semantic discovery,
|
|
6
|
+
activation, values, text, and state assertions. Runtime availability depends on
|
|
7
|
+
the graphical accessibility bus plus compatible `pyatspi` bindings. The QA
|
|
8
|
+
child must not install bindings or start/replace the user's desktop bus.
|
|
9
|
+
|
|
10
|
+
`target.application` may use `pid`, `name`, or a bounded runner-owned `launch`
|
|
11
|
+
contract. `bundleId` is not a Linux identity. POSIX launch contracts stay in an
|
|
12
|
+
owned detached process group so package-manager wrappers can hand off to a GUI
|
|
13
|
+
descendant without escaping scoped cleanup.
|
|
14
|
+
|
|
15
|
+
Keyboard input is advertised only when the runtime-probed `xdotool` producer is
|
|
16
|
+
usable. Exact-window PNG evidence is advertised only when the helper can use a
|
|
17
|
+
supported screenshot producer such as `gnome-screenshot` or `scrot`. Window
|
|
18
|
+
video is currently unavailable and remains an explicit missing capability.
|
|
19
|
+
|
|
20
|
+
Use the common desktop semantic actions/selectors and prefer AT-SPI
|
|
21
|
+
role/name/state as the oracle. If accessibility bus, bindings, keyboard, or
|
|
22
|
+
screenshot producer is missing, preserve the runner's precise capability
|
|
23
|
+
blocker instead of silently changing automation strategy.
|
|
24
|
+
|
|
25
|
+
Cleanup is scoped to the runner-owned POSIX process group; attached applications
|
|
26
|
+
remain externally owned.
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# Desktop detail: macOS Accessibility
|
|
2
|
+
|
|
3
|
+
Load this topic only when `selection.guide.topic` is `macos-accessibility`.
|
|
4
|
+
|
|
5
|
+
The trusted bundled driver uses macOS Accessibility for semantic discovery and
|
|
6
|
+
interaction, CGWindow for window correlation/capture support, and
|
|
7
|
+
ScreenCaptureKit for exact-window recording when available. Do not invoke those
|
|
8
|
+
APIs directly from the QA child.
|
|
9
|
+
|
|
10
|
+
`target.application` may identify one application by `pid`, `name`, `bundleId`,
|
|
11
|
+
or a bounded runner-owned `launch` contract. Launch wrappers remain inside the
|
|
12
|
+
owned POSIX process group so the runner can correlate the real GUI descendant
|
|
13
|
+
and perform scoped cleanup.
|
|
14
|
+
|
|
15
|
+
Accessibility permission is required for semantic QA. Exact-window screenshots
|
|
16
|
+
require Screen Recording permission; exact-window MP4 additionally requires
|
|
17
|
+
the ScreenCaptureKit window-stream capability. Probe advertises these
|
|
18
|
+
independently and returns remediation when permissions/toolchain are missing.
|
|
19
|
+
Never change macOS privacy settings from this child.
|
|
20
|
+
|
|
21
|
+
Supported semantic actions/selectors are those in the desktop base guide.
|
|
22
|
+
Prefer Accessibility roles/names/state as the oracle. Supported runs attempt a
|
|
23
|
+
silent exact-window video automatically; no extra recording action is needed.
|
|
24
|
+
The recorder scales the captured independent window to fill its Retina output
|
|
25
|
+
surface, so the window rather than an oversized empty canvas is the visual
|
|
26
|
+
evidence.
|
|
27
|
+
|
|
28
|
+
Attached applications remain externally owned. For launched applications,
|
|
29
|
+
cleanup is limited to the runner-owned process group and correlated GUI target.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Desktop detail: Windows UI Automation
|
|
2
|
+
|
|
3
|
+
Load this topic only when `selection.guide.topic` is `windows-uia`.
|
|
4
|
+
|
|
5
|
+
The trusted bundled PowerShell/.NET helper uses Windows UI Automation for
|
|
6
|
+
semantic discovery, interaction, and state assertions. Exact-window PNG capture
|
|
7
|
+
uses the bounded Win32 capture path exposed by that helper. The QA child must
|
|
8
|
+
not execute arbitrary PowerShell automation itself.
|
|
9
|
+
|
|
10
|
+
`target.application` may use `pid`, `name`, or a bounded runner-owned `launch`
|
|
11
|
+
contract. `bundleId` is not a Windows identity. For launched applications the
|
|
12
|
+
launcher PID is an owned process-tree root; UI Automation correlates the actual
|
|
13
|
+
GUI descendant before interaction and the runner retains that GUI PID as an
|
|
14
|
+
additional scoped cleanup root.
|
|
15
|
+
|
|
16
|
+
Probe verifies that UI Automation can initialize in the current interactive
|
|
17
|
+
desktop session and separately reports screenshot capability. Window video is
|
|
18
|
+
currently unavailable and must remain an explicit missing capability rather
|
|
19
|
+
than being synthesized from screenshots.
|
|
20
|
+
|
|
21
|
+
Use the common desktop semantic actions/selectors. Prefer UIA role/name/state
|
|
22
|
+
oracles, retain PNG evidence when available, and never terminate an externally
|
|
23
|
+
attached application or an unrelated process with the same name.
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# Native desktop backend router
|
|
2
|
+
|
|
3
|
+
Load this guide only after the common UI-QA role classified the requested
|
|
4
|
+
surface as `desktop`. Use the unified runner and its semantic desktop driver;
|
|
5
|
+
do not choose a platform automation stack yourself.
|
|
6
|
+
|
|
7
|
+
## Route by probe result
|
|
8
|
+
|
|
9
|
+
Desktop routing is capability-probed from the actual host. Write the common
|
|
10
|
+
flow, run `probe`, then load exactly the topic returned in `selection.guide`:
|
|
11
|
+
|
|
12
|
+
```sh
|
|
13
|
+
node "$PI_UI_QA_RUNNER" guide --backend desktop --topic macos-accessibility
|
|
14
|
+
node "$PI_UI_QA_RUNNER" guide --backend desktop --topic windows-uia
|
|
15
|
+
node "$PI_UI_QA_RUNNER" guide --backend desktop --topic linux-at-spi
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Do not infer this topic from a project name or merely from the OS label. The
|
|
19
|
+
probe also verifies runtime dependencies/permissions. If it returns `BLOCKED`,
|
|
20
|
+
relay `blockedHandoff` and stop instead of installing automation packages,
|
|
21
|
+
changing privacy/accessibility settings, or substituting another surface.
|
|
22
|
+
|
|
23
|
+
Before `run`, the loaded topic must equal the authoritative `selection.guide`.
|
|
24
|
+
|
|
25
|
+
## Common desktop flow
|
|
26
|
+
|
|
27
|
+
Set `target.application` to exactly one supported identity/launch contract. The
|
|
28
|
+
detail guide documents any platform-specific identity restrictions. Common
|
|
29
|
+
steps are:
|
|
30
|
+
|
|
31
|
+
- window/control: `waitForWindow`, `activateWindow`, `activate`;
|
|
32
|
+
- inspection: `snapshotAccessibility`;
|
|
33
|
+
- input: `setValue`, `inputText`, `pressKey`;
|
|
34
|
+
- assertions: `waitForText`, `assertText`, `assertState`;
|
|
35
|
+
- evidence: `screenshot`, `capture`.
|
|
36
|
+
|
|
37
|
+
Semantic selectors use `path` or `name`, with optional `role` and `occurrence`.
|
|
38
|
+
Prefer stable application-owned names/roles/labels/IDs over coordinates.
|
|
39
|
+
|
|
40
|
+
Launch contracts must remain runner-owned and bounded. The runner permits only
|
|
41
|
+
the documented safe environment subset plus `PI_UI_QA_*` bootstrap variables
|
|
42
|
+
and injects `PI_UI_QA=1`. Do not daemonize the app or deliberately move it
|
|
43
|
+
outside the ownership boundary.
|
|
44
|
+
|
|
45
|
+
## Oracles, evidence, cleanup
|
|
46
|
+
|
|
47
|
+
Prefer accessibility/app-driver state, window/dialog state, visible copy, and
|
|
48
|
+
enabled/checked/value state as deterministic oracles. Screenshots/videos are
|
|
49
|
+
supporting evidence. Repeated evidence actions may omit names; the runner gives
|
|
50
|
+
them collision-free filenames.
|
|
51
|
+
|
|
52
|
+
Inspect representative screenshots before visual claims. Let the runner clean
|
|
53
|
+
up only processes/windows it launched. Attached applications are externally
|
|
54
|
+
owned and must not be terminated; never broadly kill by application name.
|
package/external/pi-tools-suite/src/async-subagents/agents/ui-qa/guides/tui-native-terminal.md
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
# TUI detail: native terminal
|
|
2
|
+
|
|
3
|
+
Load this topic only when the TUI router or `selection.guide` selected
|
|
4
|
+
`native-terminal`. Set `target.command.presentation: "native-terminal"`.
|
|
5
|
+
|
|
6
|
+
## Presentation contract
|
|
7
|
+
|
|
8
|
+
The target still runs directly in the runner-owned PTY used for deterministic
|
|
9
|
+
input and semantic assertions. The runner mirrors that exact PTY byte stream
|
|
10
|
+
through a private authenticated local bridge into a fresh owned native terminal
|
|
11
|
+
window. Target argv/cwd/env are never typed into or embedded in a terminal
|
|
12
|
+
shell; the native window bootstrap contains only the trusted bridge plus
|
|
13
|
+
runner-generated transport parameters.
|
|
14
|
+
|
|
15
|
+
The runner discovers a native terminal host from current machine capabilities,
|
|
16
|
+
not project identity. Current platform providers are:
|
|
17
|
+
|
|
18
|
+
- macOS: iTerm2 when installed, otherwise Terminal.app;
|
|
19
|
+
- Windows: Windows Terminal;
|
|
20
|
+
- Linux: kitty, then Alacritty, GNOME Terminal, Konsole, then xterm.
|
|
21
|
+
|
|
22
|
+
The presentation is available only when the correlated platform desktop driver
|
|
23
|
+
can also capture the owned terminal window. Missing host/dependency/permission
|
|
24
|
+
returns `BLOCKED`; do not downgrade to headless evidence when pixel fidelity is
|
|
25
|
+
part of the requested proof.
|
|
26
|
+
|
|
27
|
+
## Flow surface
|
|
28
|
+
|
|
29
|
+
Supported PTY-semantic actions are:
|
|
30
|
+
|
|
31
|
+
- stability/navigation: `waitForStable`, `waitForText`;
|
|
32
|
+
- input: `sendText`, `sendKeys`;
|
|
33
|
+
- assertions: `assertText`, `assertNotText`, `assertCursor`,
|
|
34
|
+
`assertProcessRunning`, `assertProcessExited`;
|
|
35
|
+
- evidence: `capture`.
|
|
36
|
+
|
|
37
|
+
`viewport` and `resize` are intentionally unavailable because the actual native
|
|
38
|
+
terminal geometry and owned PTY must stay synchronized. Never simulate a resize
|
|
39
|
+
that the real window did not perform.
|
|
40
|
+
|
|
41
|
+
Both automated input and terminal-protocol responses flow through the same PTY,
|
|
42
|
+
so semantic assertions and native visual evidence refer to one target instance.
|
|
43
|
+
After input, wait for observable/stable state before asserting or capturing.
|
|
44
|
+
|
|
45
|
+
## Evidence semantics
|
|
46
|
+
|
|
47
|
+
Headless screen captures and asciicast are retained only as semantic diagnostic
|
|
48
|
+
evidence and the replay is marked diagnostic-only. Each `capture` also retains
|
|
49
|
+
a real exact-window screenshot; those pixels are the visual source of truth for
|
|
50
|
+
rendering claims. macOS can additionally publish bounded exact-window MP4 when
|
|
51
|
+
Screen Recording/ScreenCaptureKit are available. Windows/Linux currently do not
|
|
52
|
+
advertise native-terminal window video.
|
|
53
|
+
|
|
54
|
+
Real-window evidence still does not replace deterministic PTY assertions.
|
|
55
|
+
Inspect at least one meaningful screenshot before claiming colors/layout/glyph
|
|
56
|
+
fidelity.
|
|
57
|
+
|
|
58
|
+
Cleanup is scoped to the owned target PTY, private bridge, and fresh terminal
|
|
59
|
+
host. Never attach to or close an unrelated user terminal window.
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# TUI detail: PTY
|
|
2
|
+
|
|
3
|
+
Load this topic only when the TUI router or `selection.guide` selected `pty`.
|
|
4
|
+
Set `target.command.presentation: "pty"` explicitly in new flows.
|
|
5
|
+
|
|
6
|
+
## Flow surface
|
|
7
|
+
|
|
8
|
+
The runner drives one real pseudo-terminal and maintains a bundled headless
|
|
9
|
+
ANSI/VT screen model. Supported actions are:
|
|
10
|
+
|
|
11
|
+
- stability/navigation: `waitForStable`, `waitForText`;
|
|
12
|
+
- input: `sendText`, `sendKeys`, `resize`;
|
|
13
|
+
- assertions: `assertText`, `assertNotText`, `assertCursor`,
|
|
14
|
+
`assertProcessRunning`, `assertProcessExited`;
|
|
15
|
+
- evidence: `capture`.
|
|
16
|
+
|
|
17
|
+
`sendKeys` uses documented named keys; do not embed control characters into
|
|
18
|
+
model-authored text. Optional `viewport` supplies `cols`/`rows`, and `resize`
|
|
19
|
+
may change them when terminal dimensions are part of the product contract.
|
|
20
|
+
|
|
21
|
+
After input expected to change the screen, prefer `waitForText` or
|
|
22
|
+
`waitForStable` before the corresponding assertion/capture. Cursor and process
|
|
23
|
+
assertions are valid only when that state itself is part of the user-visible
|
|
24
|
+
acceptance criterion.
|
|
25
|
+
|
|
26
|
+
## Evidence semantics
|
|
27
|
+
|
|
28
|
+
Every PTY run automatically publishes a bounded asciicast v2 replay. It is a
|
|
29
|
+
terminal-state chronology, not pixel evidence: do not claim exact colors,
|
|
30
|
+
fonts, glyph rendering, or native window geometry from it. `capture` retains the
|
|
31
|
+
headless screen state for diagnosis.
|
|
32
|
+
|
|
33
|
+
If exact rendered terminal visuals are required, this is the wrong route; use
|
|
34
|
+
`native-terminal` rather than treating a headless rerender as visual proof.
|
|
35
|
+
|
|
36
|
+
Cleanup terminates only the runner-owned PTY/target. Do not signal unrelated
|
|
37
|
+
processes.
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# Terminal/TUI backend router
|
|
2
|
+
|
|
3
|
+
Load this guide only after the common UI-QA role classified the requested
|
|
4
|
+
surface as `tui`. The actual program must run through the unified runner's owned
|
|
5
|
+
PTY; never replace an interactive UI request with captured stdout from another
|
|
6
|
+
CLI path.
|
|
7
|
+
|
|
8
|
+
## Choose one presentation route
|
|
9
|
+
|
|
10
|
+
Choose from the user-facing acceptance surface, never from an application or
|
|
11
|
+
repository name:
|
|
12
|
+
|
|
13
|
+
- line-oriented/plain terminal or deliberately protocol-focused checks where
|
|
14
|
+
text/cursor/process/resize/ANSI semantics are the product -> `pty`;
|
|
15
|
+
- structured/full-screen terminal UI where rendered layout, colors, glyphs,
|
|
16
|
+
menus, wrapping, clipping, focus, or terminal-window fidelity matter ->
|
|
17
|
+
`native-terminal`.
|
|
18
|
+
|
|
19
|
+
Load exactly one detail topic:
|
|
20
|
+
|
|
21
|
+
```sh
|
|
22
|
+
node "$PI_UI_QA_RUNNER" guide --backend tui --topic pty
|
|
23
|
+
node "$PI_UI_QA_RUNNER" guide --backend tui --topic native-terminal
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
For every new flow, explicitly set `target.command.presentation` to the route
|
|
27
|
+
you selected. Omission remains accepted only for old-flow compatibility. If the
|
|
28
|
+
requested visual fidelity requires `native-terminal` and probe blocks it, relay
|
|
29
|
+
the blocker rather than silently downgrading to PTY evidence.
|
|
30
|
+
|
|
31
|
+
After `probe`, `selection.guide` is authoritative and must equal the detail
|
|
32
|
+
topic you are following before `run`. If it differs, load the returned topic and
|
|
33
|
+
reconcile the flow first.
|
|
34
|
+
|
|
35
|
+
## Common TUI flow
|
|
36
|
+
|
|
37
|
+
Set `target.command` to the bounded argv/cwd/env launch contract for the actual
|
|
38
|
+
shipping interactive program. Generic shells, arbitrary utility launchers, and
|
|
39
|
+
inline-code execution are not an automation escape hatch. The runner launches
|
|
40
|
+
the target directly in its owned PTY.
|
|
41
|
+
|
|
42
|
+
Input must be user-equivalent. Define the expected visible/interactive
|
|
43
|
+
postcondition before sending keys, and wait for observable text or a stable
|
|
44
|
+
frame before asserting asynchronous state changes. The detail guide defines the
|
|
45
|
+
supported actions and evidence for its presentation.
|
|
46
|
+
|
|
47
|
+
Use only the documented bounded environment fields and project-local launch
|
|
48
|
+
paths. Do not edit product source/tests/settings or signal/mutate target state
|
|
49
|
+
behind the UI merely to make the flow pass.
|
|
50
|
+
|
|
51
|
+
## Oracles, evidence, cleanup
|
|
52
|
+
|
|
53
|
+
Deterministic terminal text/cursor/process assertions are the pass/fail oracle
|
|
54
|
+
when those states are product-visible. Pixel captures and terminal recordings
|
|
55
|
+
explain the result and do not replace assertions. Preserve failing evidence.
|
|
56
|
+
|
|
57
|
+
Let the runner clean up only the PTY/process and presentation resources it owns.
|
|
58
|
+
Never attach to, type into, or broadly terminate unrelated user terminal
|
|
59
|
+
windows/processes. Report every retained artifact and inspect representative
|
|
60
|
+
PNG evidence before making visual rendering claims.
|