@reticlehq/server 2.7.0 → 2.8.0
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 +14 -5
- package/SKILL.md +64 -29
- package/dist/capsule/causal-summary.d.ts +20 -0
- package/dist/capsule/causal-summary.js +31 -6
- package/dist/capsule/divergence.js +7 -1
- package/dist/cli/chromium-hint.d.ts +33 -5
- package/dist/cli/chromium-hint.js +82 -12
- package/dist/cli/cli-doctor.js +28 -25
- package/dist/cli/cli-kill.d.ts +58 -0
- package/dist/cli/cli-kill.js +162 -0
- package/dist/cli/cli-launch.d.ts +17 -0
- package/dist/cli/cli-launch.js +28 -0
- package/dist/cli/cli-parse.d.ts +16 -1
- package/dist/cli/cli-parse.js +32 -9
- package/dist/cli/cli-port.d.ts +8 -0
- package/dist/cli/cli-port.js +16 -0
- package/dist/cli/cli-verify.js +2 -2
- package/dist/cli/doctor-sessions-line.d.ts +12 -0
- package/dist/cli/doctor-sessions-line.js +66 -0
- package/dist/cli/port-holder.d.ts +10 -0
- package/dist/cli/port-holder.js +26 -2
- package/dist/cli.js +99 -14
- package/dist/crawl/crawl-tools.js +12 -2
- package/dist/crawl/crawl.d.ts +13 -0
- package/dist/crawl/crawl.js +50 -2
- package/dist/events/contradictions.d.ts +14 -0
- package/dist/events/contradictions.js +26 -17
- package/dist/events/predicate-eval.d.ts +20 -1
- package/dist/events/predicate-eval.js +125 -3
- package/dist/events/predicate.js +170 -18
- package/dist/flows/flow-classify.js +1 -1
- package/dist/flows/flow-tools.js +12 -4
- package/dist/flows/heal-run.js +1 -1
- package/dist/honesty/blind-spots.js +6 -2
- package/dist/honesty/unsettled.d.ts +40 -0
- package/dist/honesty/unsettled.js +78 -0
- package/dist/honesty/verified.d.ts +7 -0
- package/dist/honesty/verified.js +3 -3
- package/dist/index.js +3 -0
- package/dist/init/agent-rules.d.ts +16 -0
- package/dist/init/agent-rules.js +96 -22
- package/dist/init/astro-patch.d.ts +2 -1
- package/dist/init/astro-patch.js +11 -5
- package/dist/init/capabilities.d.ts +22 -0
- package/dist/init/capabilities.js +76 -0
- package/dist/init/confirm.d.ts +96 -0
- package/dist/init/confirm.js +138 -0
- package/dist/init/cra.js +3 -2
- package/dist/init/non-js-project.js +29 -5
- package/dist/init/plan-framework.js +53 -15
- package/dist/init/plan.d.ts +40 -4
- package/dist/init/plan.js +163 -40
- package/dist/init/run.d.ts +24 -2
- package/dist/init/run.js +148 -42
- package/dist/init/slash-command.d.ts +1 -1
- package/dist/init/slash-command.js +46 -6
- package/dist/init/snippets.d.ts +44 -4
- package/dist/init/snippets.js +161 -37
- package/dist/init/vite-config.js +29 -3
- package/dist/input/network-mock-tools.d.ts +19 -0
- package/dist/input/network-mock-tools.js +29 -4
- package/dist/license/license.js +1 -1
- package/dist/mcp/mcp-proxy.d.ts +69 -3
- package/dist/mcp/mcp-proxy.js +205 -20
- package/dist/mcp/mcp.js +23 -7
- package/dist/mcp/proxy-lifecycle.d.ts +1 -1
- package/dist/mcp/proxy-lifecycle.js +1 -1
- package/dist/pool/browser-pool.d.ts +22 -2
- package/dist/pool/browser-pool.js +44 -4
- package/dist/project/learned-routes.d.ts +24 -0
- package/dist/project/learned-routes.js +63 -0
- package/dist/project/project-store.d.ts +6 -0
- package/dist/project/project-store.js +25 -1
- package/dist/session/no-session-diagnosis.d.ts +19 -0
- package/dist/session/no-session-diagnosis.js +71 -18
- package/dist/session/no-session-watch.js +12 -0
- package/dist/session/ref-provenance.d.ts +54 -0
- package/dist/session/ref-provenance.js +61 -0
- package/dist/session/session-lease.js +1 -1
- package/dist/telemetry/automation-hint.d.ts +17 -0
- package/dist/telemetry/automation-hint.js +71 -0
- package/dist/telemetry/bug-found.d.ts +0 -20
- package/dist/telemetry/bug-found.js +38 -21
- package/dist/telemetry/cli-telemetry.js +7 -1
- package/dist/telemetry/feedback.js +1 -1
- package/dist/telemetry/init-telemetry.js +9 -1
- package/dist/telemetry/install-source.d.ts +36 -0
- package/dist/telemetry/install-source.js +40 -0
- package/dist/telemetry/run-telemetry.js +4 -1
- package/dist/telemetry/session-metrics.js +5 -0
- package/dist/telemetry/telemetry.d.ts +5 -1
- package/dist/telemetry/telemetry.js +15 -2
- package/dist/telemetry/tool-refused.d.ts +19 -0
- package/dist/telemetry/tool-refused.js +55 -0
- package/dist/telemetry/verification-of.js +46 -7
- package/dist/temp-dir.d.ts +27 -0
- package/dist/temp-dir.js +46 -0
- package/dist/tools/act-tools.js +45 -1
- package/dist/tools/assert-grade.d.ts +1 -1
- package/dist/tools/assert-grade.js +27 -5
- package/dist/tools/assert-verdict.js +18 -1
- package/dist/tools/contract-tools.js +4 -0
- package/dist/tools/dynamic-tools.js +1 -1
- package/dist/tools/error-recovery.d.ts +10 -0
- package/dist/tools/error-recovery.js +64 -4
- package/dist/tools/feedback-invite.js +1 -1
- package/dist/tools/invoke-tool.js +139 -23
- package/dist/tools/lease-tools.d.ts +29 -1
- package/dist/tools/lease-tools.js +58 -5
- package/dist/tools/navigate-result.js +1 -1
- package/dist/tools/observe-tools.js +1 -1
- package/dist/tools/observed-nothing.js +1 -1
- package/dist/tools/react-grace.d.ts +48 -0
- package/dist/tools/react-grace.js +87 -0
- package/dist/tools/read-tools.js +20 -4
- package/dist/tools/settle-in-flight.d.ts +79 -0
- package/dist/tools/settle-in-flight.js +106 -0
- package/dist/tools/snapshot-delta.d.ts +7 -0
- package/dist/tools/snapshot-delta.js +130 -6
- package/dist/tools/tool-surface.js +19 -0
- package/dist/tools/tools.js +16 -4
- package/docs/README.md +56 -11
- package/docs/actions.mdx +87 -0
- package/docs/agent-cheatsheet.md +93 -29
- package/docs/architecture.md +46 -35
- package/docs/benchmarks.md +76 -72
- package/docs/best-practices.mdx +211 -0
- package/docs/capabilities.mdx +387 -0
- package/docs/cli/affected.mdx +51 -0
- package/docs/cli/capsules.mdx +69 -0
- package/docs/cli/cloud.mdx +127 -0
- package/docs/cli/doctor.mdx +76 -0
- package/docs/cli/drive.mdx +55 -0
- package/docs/cli/feedback.mdx +67 -0
- package/docs/cli/gate.mdx +64 -0
- package/docs/cli/help.mdx +92 -0
- package/docs/cli/hunt.mdx +57 -0
- package/docs/cli/identify.mdx +62 -0
- package/docs/cli/init.mdx +94 -0
- package/docs/cli/kill.mdx +91 -0
- package/docs/cli/license.mdx +48 -0
- package/docs/cli/mcp.mdx +61 -0
- package/docs/cli/open.mdx +68 -0
- package/docs/cli/restart.mdx +60 -0
- package/docs/cli/rollback.mdx +35 -0
- package/docs/cli/serve.mdx +62 -0
- package/docs/cli/status.mdx +64 -0
- package/docs/cli/stop.mdx +56 -0
- package/docs/cli/telemetry.mdx +57 -0
- package/docs/cli/update.mdx +52 -0
- package/docs/cli/verify.mdx +57 -0
- package/docs/cli/version.mdx +39 -0
- package/docs/cli/watch.mdx +55 -0
- package/docs/cli.mdx +219 -0
- package/docs/debugging.md +13 -9
- package/docs/deploy-checks.md +15 -11
- package/docs/desktop-apps.md +49 -40
- package/docs/desktop.mdx +188 -0
- package/docs/docs.json +363 -0
- package/docs/enterprise.md +20 -16
- package/docs/faq.mdx +88 -0
- package/docs/fixtures.md +11 -7
- package/docs/flows.md +26 -22
- package/docs/for-agents.md +71 -0
- package/docs/frameworks.mdx +199 -0
- package/docs/gate-plan.md +45 -41
- package/docs/gates.md +22 -18
- package/docs/getting-started.md +76 -65
- package/docs/human-control.md +22 -18
- package/docs/index.mdx +101 -0
- package/docs/install-agentic.mdx +215 -0
- package/docs/install-manual.mdx +194 -0
- package/docs/instrumentation.mdx +232 -0
- package/docs/integration-patterns.md +38 -34
- package/docs/local-registry.md +16 -12
- package/docs/multi-agent-testing.md +16 -12
- package/docs/packages/babel-plugin.mdx +70 -0
- package/docs/packages/browser.mdx +111 -0
- package/docs/packages/core.mdx +106 -0
- package/docs/packages/electron.mdx +87 -0
- package/docs/packages/eslint-plugin.mdx +84 -0
- package/docs/packages/next.mdx +91 -0
- package/docs/packages/react.mdx +91 -0
- package/docs/packages/server.mdx +98 -0
- package/docs/packages/tauri.mdx +63 -0
- package/docs/packages/test.mdx +108 -0
- package/docs/packages/vite-plugin.mdx +96 -0
- package/docs/packages.mdx +217 -0
- package/docs/platform-integration.md +33 -26
- package/docs/predicates.mdx +179 -0
- package/docs/quickstart.mdx +211 -0
- package/docs/recipes.mdx +242 -0
- package/docs/skill-file.mdx +105 -0
- package/docs/state-management.mdx +197 -0
- package/docs/style.css +14 -0
- package/docs/system-map.md +47 -32
- package/docs/telemetry-contract.md +93 -50
- package/docs/telemetry-events.mdx +430 -0
- package/docs/telemetry.md +57 -52
- package/docs/testing.md +10 -6
- package/docs/token-efficiency.md +30 -26
- package/docs/tools-act-and-wait.mdx +123 -0
- package/docs/tools-act-sequence.mdx +120 -0
- package/docs/tools-act.mdx +82 -0
- package/docs/tools-assert.mdx +70 -0
- package/docs/tools-console.mdx +59 -0
- package/docs/tools-inspect.mdx +85 -0
- package/docs/tools-navigate.mdx +63 -0
- package/docs/tools-network.mdx +86 -0
- package/docs/tools-observe.mdx +89 -0
- package/docs/tools-overview.mdx +157 -0
- package/docs/tools-query.mdx +82 -0
- package/docs/tools-session-and-feedback.mdx +91 -0
- package/docs/tools-sessions.mdx +65 -0
- package/docs/tools-snapshot.mdx +75 -0
- package/docs/tools-state.mdx +81 -0
- package/docs/tools-tools-and-run.mdx +125 -0
- package/docs/tools-wait-for.mdx +66 -0
- package/docs/troubleshooting.mdx +193 -0
- package/docs/usage.md +175 -153
- package/docs/vs-chrome-devtools-mcp.mdx +82 -0
- package/docs/vs-playwright-mcp.mdx +85 -0
- package/docs/vs-screenshots.mdx +96 -0
- package/docs/what-is-reticle.mdx +63 -0
- package/docs/why-reticle.mdx +107 -0
- package/package.json +2 -2
- package/docs/matrix/2.5.0/claude-code-machine.json +0 -19
- package/docs/matrix/2.5.0/codex-machine.json +0 -20
- package/docs/matrix/2.5.0/cursor-machine.json +0 -22
- package/docs/matrix/2.5.0/gemini-machine.json +0 -22
- package/docs/matrix/2.5.0/opencode-machine.json +0 -22
- package/docs/matrix/2.5.0/vscode-machine.json +0 -22
- package/docs/matrix/2.5.0/windsurf-machine.json +0 -22
- package/docs/matrix/MATRIX.md +0 -26
- package/docs/matrix/README.md +0 -59
- package/docs/mint.json +0 -61
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: reticle watch
|
|
3
|
+
description: Watch the working tree and report which saved flows must re-verify on every save.
|
|
4
|
+
icon: eye
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
`reticle watch` is the buddy loop. It watches the current directory and, on every save of a source file, reports which saved flows the change puts at risk. It runs in the environment, so it costs your agent nothing per turn.
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npx @reticlehq/server watch [url]
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Long-running. Stop it with `Ctrl+C`.
|
|
14
|
+
|
|
15
|
+
## Arguments
|
|
16
|
+
|
|
17
|
+
| Argument | Type | Default | What it does |
|
|
18
|
+
| --- | --- | --- | --- |
|
|
19
|
+
| `url` | string, positional, optional | unset | Accepted by the parser and reserved for the increment that replays the affected flows against a live app. The current version detects and reports only |
|
|
20
|
+
|
|
21
|
+
## What it watches
|
|
22
|
+
|
|
23
|
+
The working directory, recursively, filtered to `.ts`, `.tsx`, `.js`, `.jsx`, `.mjs`, `.cjs`, `.vue` and `.svelte`. Changes are batched with a 200ms debounce.
|
|
24
|
+
|
|
25
|
+
## What it prints
|
|
26
|
+
|
|
27
|
+
Real capture, the first two lines of a run in this repository:
|
|
28
|
+
|
|
29
|
+
```json
|
|
30
|
+
{"t":"2026-08-14T19:39:09.196Z","event":"reticle_watch_started","cwd":"/Users/you/reticle"}
|
|
31
|
+
{"t":"2026-08-14T19:39:09.278Z","event":"reticle_buddy","status":"✓ 13/47 flows nominal · 9 flaky quarantined"}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
| Event | When |
|
|
35
|
+
| --- | --- |
|
|
36
|
+
| `reticle_watch_started` | Once, at startup, with the directory being watched |
|
|
37
|
+
| `reticle_buddy` | Once at startup and after every batch. One ambient line, designed to be parked in a status line |
|
|
38
|
+
| `reticle_watch_affected` | After a batch, when at least one flow is affected. Carries `changed` and `affected` |
|
|
39
|
+
| `reticle_watch_failed` | A flow load error. Never fatal |
|
|
40
|
+
|
|
41
|
+
<Note>
|
|
42
|
+
The buddy line is deliberately best-effort and silent on failure. A status line that throws is
|
|
43
|
+
worse than no status line, and it must never interfere with the watch loop it rides on.
|
|
44
|
+
</Note>
|
|
45
|
+
|
|
46
|
+
## Exit codes
|
|
47
|
+
|
|
48
|
+
Runs until interrupted.
|
|
49
|
+
|
|
50
|
+
## Worked example
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
npx @reticlehq/server watch &
|
|
54
|
+
# edit src/components/Login.tsx, and the affected flows are named on save
|
|
55
|
+
```
|
package/docs/cli.mdx
ADDED
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: CLI reference
|
|
3
|
+
description: Every reticle command. What it does, what it prints, and what it exits with. Captured from real runs.
|
|
4
|
+
icon: terminal
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
The CLI is mostly for you, not your agent. Your agent talks MCP; you use these to set things up, work out why nothing connected, and wire verification into CI.
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npx @reticlehq/server <command>
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
<Warning>
|
|
14
|
+
**Always invoke it as `npx @reticlehq/server <command>`.** The tables below name the commands as
|
|
15
|
+
`reticle <command>`, because `reticle` is the bin this package installs and that is what the CLI
|
|
16
|
+
prints about itself. It is **not** a package on npm: the bare name `reticle` belongs to an
|
|
17
|
+
unrelated author, so putting `npx` in front of it downloads and runs their code instead of ours.
|
|
18
|
+
Once
|
|
19
|
+
`@reticlehq/server` is a dependency of your project, `reticle <command>` works from an npm script
|
|
20
|
+
or with the bin on your PATH.
|
|
21
|
+
</Warning>
|
|
22
|
+
|
|
23
|
+
<Note>
|
|
24
|
+
Every output block on this page was captured by running the command. Where an exit code is quoted,
|
|
25
|
+
it was measured, not assumed.
|
|
26
|
+
</Note>
|
|
27
|
+
|
|
28
|
+
## Setup and diagnosis
|
|
29
|
+
|
|
30
|
+
### `reticle init`
|
|
31
|
+
|
|
32
|
+
Wires Reticle into the project in the current directory.
|
|
33
|
+
|
|
34
|
+
```
|
|
35
|
+
reticle init [--dry-run] [--port N] [--no-mcp] [--no-install] [--app <dir>]
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
<Card title="Full walkthrough with real output" icon="wand-magic-sparkles" href="/install-agentic">
|
|
39
|
+
What it writes, and how to read its four status marks.
|
|
40
|
+
</Card>
|
|
41
|
+
|
|
42
|
+
### `reticle doctor`
|
|
43
|
+
|
|
44
|
+
The first thing to run when something is wrong. One command, the whole setup.
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
npx @reticlehq/server doctor
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
```
|
|
51
|
+
reticle doctor
|
|
52
|
+
node v22.14.0
|
|
53
|
+
chromium ✓ installed
|
|
54
|
+
daemon ✓ running on :4400 (pid 24735, v2.8.0)
|
|
55
|
+
sessions ✓ 1 page connected
|
|
56
|
+
bridge port 4400 (your app must dial THIS port, not your dev-server port)
|
|
57
|
+
daemon log /Users/you/.reticle/daemon-4400.log
|
|
58
|
+
tracing RETICLE_TRACE=1 on the daemon for per-stage timings in that log
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Exits `0`. That parenthetical about the bridge port is doing a lot of work. Mixing it up with the dev-server port is the most common setup failure there is.
|
|
62
|
+
|
|
63
|
+
### `reticle status`
|
|
64
|
+
|
|
65
|
+
Whether the daemon is up and which apps have connected.
|
|
66
|
+
|
|
67
|
+
```json
|
|
68
|
+
{
|
|
69
|
+
"event": "reticle_status",
|
|
70
|
+
"port": 4400,
|
|
71
|
+
"running": true,
|
|
72
|
+
"pid": 24735,
|
|
73
|
+
"sessionCount": 1,
|
|
74
|
+
"sessions": [
|
|
75
|
+
{
|
|
76
|
+
"sessionId": "sece96901…",
|
|
77
|
+
"url": "http://localhost:4312/",
|
|
78
|
+
"throttled": true,
|
|
79
|
+
"stale": false
|
|
80
|
+
}
|
|
81
|
+
]
|
|
82
|
+
}
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
Exits `0`. A session in the list is the install genuinely finished. Not a tick in a checklist, a connected app.
|
|
86
|
+
|
|
87
|
+
### `reticle telemetry [status|enable|disable]`
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
npx @reticlehq/server telemetry status
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
```
|
|
94
|
+
telemetry disabled (this is a Reticle source checkout; developing it is not using it)
|
|
95
|
+
policy https://github.com/reticlehq/reticle/blob/main/docs/telemetry.md
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
<Card title="Exactly what is collected" icon="chart-line" href="/telemetry">
|
|
99
|
+
The complete list, and how to turn it off.
|
|
100
|
+
</Card>
|
|
101
|
+
|
|
102
|
+
## Running the app
|
|
103
|
+
|
|
104
|
+
| Command | What it does |
|
|
105
|
+
| --- | --- |
|
|
106
|
+
| `reticle serve` | Start the daemon in the foreground. `--drive <url>`, `--headless`, `--http` |
|
|
107
|
+
| `reticle stop` | Stop it |
|
|
108
|
+
| `reticle open [url]` | Show the app. Reuse the connected tab, or open one |
|
|
109
|
+
| `reticle drive <url>` | Foreground mode, for debugging |
|
|
110
|
+
| `reticle mcp` | The MCP stdio proxy. Auto-starts the daemon if needed. This is what your agent runs |
|
|
111
|
+
|
|
112
|
+
<Warning>
|
|
113
|
+
`reticle drive` will fail with an `EADDRINUSE` stack trace if a daemon is already listening on the
|
|
114
|
+
port. Which is the normal state once your agent has started one. `reticle mcp` reuses a running
|
|
115
|
+
daemon; `drive` currently does not.
|
|
116
|
+
</Warning>
|
|
117
|
+
|
|
118
|
+
## Verification
|
|
119
|
+
|
|
120
|
+
### `reticle verify <url>`
|
|
121
|
+
|
|
122
|
+
One-shot: drive the URL, replay the saved flows, exit `0` on pass. This is the command for CI when you do not want a model in the loop.
|
|
123
|
+
|
|
124
|
+
```bash
|
|
125
|
+
npx @reticlehq/server verify http://localhost:5173 --timeout 60000
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
Options: `--headed`, `--timeout N`, `--storage-state <file>`. That last one is how you verify flows behind a login without scripting the login every time.
|
|
129
|
+
|
|
130
|
+
### `reticle affected`
|
|
131
|
+
|
|
132
|
+
Which saved flows must re-verify for a set of changed files.
|
|
133
|
+
|
|
134
|
+
```bash
|
|
135
|
+
npx @reticlehq/server affected --since HEAD~1
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
```json
|
|
139
|
+
{
|
|
140
|
+
"event": "reticle_affected",
|
|
141
|
+
"changedFiles": ["docs/README.md", "packages/server/src/tools/docs-index-coverage.test.ts"],
|
|
142
|
+
"affected": ["deploy-journey", "verify-modal", "verify-route", "…"],
|
|
143
|
+
"unknownProvenance": ["deploy-journey", "verify-modal", "…"]
|
|
144
|
+
}
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
<Note>
|
|
148
|
+
`unknownProvenance` lists flows Reticle could not map to source files, so it includes them to be
|
|
149
|
+
safe. A flow recorded before provenance tracking existed has no file list, and Reticle would
|
|
150
|
+
rather re-run it than skip it and miss a regression. A large `unknownProvenance` means your flows
|
|
151
|
+
predate the feature. Re-record the ones you care about to get precise selection.
|
|
152
|
+
</Note>
|
|
153
|
+
|
|
154
|
+
### `reticle gate`
|
|
155
|
+
|
|
156
|
+
The CI gate. Exits non-zero unless passing artifacts cover the affected flows.
|
|
157
|
+
|
|
158
|
+
```bash
|
|
159
|
+
npx @reticlehq/server gate --since HEAD~1
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
```json
|
|
163
|
+
{
|
|
164
|
+
"event": "reticle_gate",
|
|
165
|
+
"pass": false,
|
|
166
|
+
"uncovered": ["deploy-journey", "verify-modal", "…"],
|
|
167
|
+
"quarantined": ["drift-demo", "qa2-flow"],
|
|
168
|
+
"coverage": { "pct": 9, "covered": 4, "total": 47 }
|
|
169
|
+
}
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
Measured exit code: **`1`**. That run genuinely failed, with 4 of 47 flows covered, which is what a gate is supposed to do when you have not verified anything yet.
|
|
173
|
+
|
|
174
|
+
`quarantined` flows are excluded from the pass/fail decision. Quarantine is for a flow that is known flaky and being fixed; it is not a place to hide failures, because the list is printed on every run.
|
|
175
|
+
|
|
176
|
+
### `reticle watch [url]`
|
|
177
|
+
|
|
178
|
+
On save, report which saved flows must re-verify. The interactive companion to `affected`.
|
|
179
|
+
|
|
180
|
+
## Maintenance
|
|
181
|
+
|
|
182
|
+
| Command | What it does |
|
|
183
|
+
| ------------------ | --------------------------------------------------- |
|
|
184
|
+
| `reticle update` | Install the latest server version and restart |
|
|
185
|
+
| `reticle rollback` | Restore the previous version and restart |
|
|
186
|
+
| `reticle license` | Enterprise license status: active, eval, or missing |
|
|
187
|
+
| `reticle version` | Print the version |
|
|
188
|
+
| `reticle help` | Usage for everything |
|
|
189
|
+
|
|
190
|
+
<Tip>
|
|
191
|
+
`rollback` exists because an auto-updating dev tool that cannot go back is a dev tool that can
|
|
192
|
+
ruin your afternoon. It restores the previous version and restarts in one step.
|
|
193
|
+
</Tip>
|
|
194
|
+
|
|
195
|
+
## Feedback
|
|
196
|
+
|
|
197
|
+
```bash
|
|
198
|
+
# humans
|
|
199
|
+
npx @reticlehq/server feedback "what worked, what didn't"
|
|
200
|
+
|
|
201
|
+
# agents, including from a setup that never finished
|
|
202
|
+
npx @reticlehq/server feedback --agent --kind <bug|gap|ambiguity|feature_request|improvement> "what happened"
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
The `--agent` form matters more than it looks: the setup that failed halfway is exactly the setup worth hearing about, and in that state the MCP tools do not exist yet.
|
|
206
|
+
|
|
207
|
+
<Card title="How feedback is handled" icon="comments" href="/tools-session-and-feedback">
|
|
208
|
+
What each kind means, and what happens when a report cannot be delivered.
|
|
209
|
+
</Card>
|
|
210
|
+
|
|
211
|
+
## `reticle identify`
|
|
212
|
+
|
|
213
|
+
Opt-in, and off by default:
|
|
214
|
+
|
|
215
|
+
```bash
|
|
216
|
+
npx @reticlehq/server identify --context company|side_project|open_source|learning [--email E] [--forget]
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
Only useful if you want support or an enterprise trial. `--forget` removes it.
|
package/docs/debugging.md
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
title: Debugging Reticle
|
|
3
|
+
description: For people working on Reticle itself. How to work out why a flow behaved the way it did.
|
|
4
|
+
icon: bug
|
|
5
|
+
---
|
|
2
6
|
|
|
3
|
-
> For people working **on** Reticle
|
|
7
|
+
> For people working **on** Reticle, and for an agent asked to explain why a flow behaved the way it did. If you are debugging **your app** with Reticle, you want [usage.md](usage.md) instead.
|
|
4
8
|
|
|
5
9
|
Reticle produces four different signals and they answer four different questions. Reaching for the wrong one is why investigations here have historically started by reading source.
|
|
6
10
|
|
|
@@ -27,7 +31,7 @@ tail -f ~/.reticle/daemon-4400.log | jq .
|
|
|
27
31
|
|
|
28
32
|
## Verbose flow tracing
|
|
29
33
|
|
|
30
|
-
Off by default, because a trace on every tool call is a cost on the hot path
|
|
34
|
+
Off by default, because a trace on every tool call is a cost on the hot path, and a verification loop is 50 to 200 calls. Measured, so the claim is checkable: a disabled span costs **126ns** per site (against ~9ns for a bare call), which is under a microsecond per tool call and not the literal zero it is tempting to write. Turn it on **for the daemon** (the flag is read per call, but the daemon is the process doing the work, so it has to be set where the daemon starts):
|
|
31
35
|
|
|
32
36
|
```bash
|
|
33
37
|
RETICLE_TRACE=1 reticle serve --port 4400
|
|
@@ -42,10 +46,10 @@ Every instrumented stage then emits one line **when it ends**, carrying its own
|
|
|
42
46
|
|
|
43
47
|
Read it like this:
|
|
44
48
|
|
|
45
|
-
- **`callId`** groups every stage of one tool call, and is prefixed with the daemon's pid so two daemons (or one that restarted) can never claim the same id. Several agents can be inside the daemon at once, so lines interleave
|
|
49
|
+
- **`callId`** groups every stage of one tool call, and is prefixed with the daemon's pid so two daemons (or one that restarted) can never claim the same id. Several agents can be inside the daemon at once, so lines interleave; the id is the only thing that makes the output a tree instead of a pile.
|
|
46
50
|
- **`depth`** is the nesting level. `0` is the tool handler; anything deeper ran inside it.
|
|
47
51
|
- **`ms`** is that stage's own wall-clock. A parent's `ms` includes its children's.
|
|
48
|
-
- **`ok:false`** carries an `error` field. A stage that threw is still traced
|
|
52
|
+
- **`ok:false`** carries an `error` field. A stage that threw is still traced; otherwise the trace would show a call that entered a stage and never left, which reads as a hang.
|
|
49
53
|
|
|
50
54
|
One line per stage, at the end, is deliberate: a start line as well would double the volume to say something the end line already implies.
|
|
51
55
|
|
|
@@ -61,7 +65,7 @@ The spans that ship today:
|
|
|
61
65
|
| `crawl.step` | one control the crawl clicked, including its settle budget |
|
|
62
66
|
| `init.plan` / `init.apply` / `init.exec` / `init.exec.retry` / `init.write` | the install, phase by phase |
|
|
63
67
|
|
|
64
|
-
The first two answer _"is this slow because of us or because of the app under test?"_
|
|
68
|
+
The first two answer _"is this slow because of us or because of the app under test?"_
|
|
65
69
|
|
|
66
70
|
`browser.command` close to `tool.handler` means the app is taking the time. A large gap between them is Reticle's own overhead, and that is a performance bug of ours.
|
|
67
71
|
|
|
@@ -79,7 +83,7 @@ grep '"event":"trace"' ~/.reticle/daemon-4400.log | jq -sc 'sort_by(-.ms)[:10] |
|
|
|
79
83
|
|
|
80
84
|
### The init flow
|
|
81
85
|
|
|
82
|
-
`reticle init` is synchronous end to end, so it uses `spanSync
|
|
86
|
+
`reticle init` is synchronous end to end, so it uses `spanSync`: same line, same tree:
|
|
83
87
|
|
|
84
88
|
```
|
|
85
89
|
init.plan 2ms
|
|
@@ -89,7 +93,7 @@ init.write 1ms target=.reticle.json
|
|
|
89
93
|
init.apply 262ms steps=5
|
|
90
94
|
```
|
|
91
95
|
|
|
92
|
-
Two things that trace makes visible and nothing else did. Planning is ~2ms, so init's wall-clock is essentially all subprocess: the package manager, and `claude mcp add` when MCP registration is on. And when the pinned install is refused, the unpinned **retry is a second full package-manager run
|
|
96
|
+
Two things that trace makes visible and nothing else did. Planning is ~2ms, so init's wall-clock is essentially all subprocess: the package manager, and `claude mcp add` when MCP registration is on. And when the pinned install is refused, the unpinned **retry is a second full package-manager run**, so init legitimately takes about twice as long on that path. Every `--local` fixture run takes it, because the version being installed is not published yet.
|
|
93
97
|
|
|
94
98
|
### Adding a span
|
|
95
99
|
|
|
@@ -99,4 +103,4 @@ import { span } from '../trace.js';
|
|
|
99
103
|
const result = await span('predicate.eval', { kind: predicate.kind }, () => evaluate(predicate));
|
|
100
104
|
```
|
|
101
105
|
|
|
102
|
-
Wrap a stage worth a line in a bottleneck hunt
|
|
106
|
+
Wrap a stage worth a line in a bottleneck hunt: a session resolve, a browser round-trip, a predicate evaluation. Not every function: the trace earns its keep by being faster to read than the code, and that stops being true somewhere around one line per statement. Nesting needs no plumbing: the call id and depth ride in `AsyncLocalStorage`, so a span added five frames down still lands in the right tree without changing anyone's signature.
|
package/docs/deploy-checks.md
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
title: Deploy checks
|
|
3
|
+
description: 'Enforce verification at the moment code becomes a preview URL, as a Vercel or Netlify check on the PR.'
|
|
4
|
+
icon: circle-check
|
|
5
|
+
---
|
|
2
6
|
|
|
3
|
-
The strongest place to enforce verification is the moment code becomes a preview URL. Every deploy already produces one, and both Vercel and Netlify let a third party attach a **check** to it
|
|
7
|
+
The strongest place to enforce verification is the moment code becomes a preview URL. Every deploy already produces one, and both Vercel and Netlify let a third party attach a **check** to it: pass/fail, shown on the PR, with no workflow file to write.
|
|
4
8
|
|
|
5
|
-
That makes the non-developer story complete: the SDK is auto-injected by the build plugin, flows are minted from toolbar recordings with auto-proposed consequences, and verification runs at publish
|
|
9
|
+
That makes the non-developer story complete: the SDK is auto-injected by the build plugin, flows are minted from toolbar recordings with auto-proposed consequences, and verification runs at publish, **without anyone writing a test.**
|
|
6
10
|
|
|
7
11
|
> Docs-only in v2.2.0. The pieces below all ship today (`reticle verify` exits 0/1 and persists a run artifact); what is _not_ built is a hosted Reticle app that registers itself as a provider. Wire it with the CI recipe until that exists.
|
|
8
12
|
|
|
@@ -14,11 +18,11 @@ git push → preview deploy → Reticle verifies the preview URL → check passe
|
|
|
14
18
|
|
|
15
19
|
`reticle verify <preview-url>` is the whole integration surface:
|
|
16
20
|
|
|
17
|
-
- exits **0** when every saved flow passes, **1** otherwise
|
|
21
|
+
- exits **0** when every saved flow passes, **1** otherwise (the only contract a check needs),
|
|
18
22
|
- prints a legible ✓/✗ report for the PR log,
|
|
19
23
|
- persists a `ReticleVerificationRun` artifact (`.reticle/runs/<id>.json`) so `reticle gate` and `reticle_run_export` can consume the same verdict.
|
|
20
24
|
|
|
21
|
-
## Recipe A
|
|
25
|
+
## Recipe A: CI (works today, any provider)
|
|
22
26
|
|
|
23
27
|
```yaml
|
|
24
28
|
# .github/workflows/verify.yml
|
|
@@ -34,14 +38,14 @@ jobs:
|
|
|
34
38
|
- run: pnpm install --frozen-lockfile
|
|
35
39
|
- run: npx playwright install --with-deps chromium
|
|
36
40
|
# Reticle drives the preview and owns its own browser + daemon.
|
|
37
|
-
- run: npx
|
|
41
|
+
- run: npx @reticlehq/server verify "${{ github.event.deployment_status.target_url }}" --timeout 60000
|
|
38
42
|
```
|
|
39
43
|
|
|
40
44
|
The job's own pass/fail becomes the PR check. Nothing else is required.
|
|
41
45
|
|
|
42
|
-
**Non-loopback previews need pairing.** For a real preview URL (not `localhost`), Reticle injects `reticle.connect()` with a one-time token and allow-lists the preview origin
|
|
46
|
+
**Non-loopback previews need pairing.** For a real preview URL (not `localhost`), Reticle injects `reticle.connect()` with a one-time token and allow-lists the preview origin, so the app does not need to be rebuilt per environment. Confirm the SDK actually runs on the deployed build: a production build that tree-shakes the dev-only SDK will connect to nothing, and `verify` will (correctly) fail with _"no app connected."_
|
|
43
47
|
|
|
44
|
-
## Recipe B
|
|
48
|
+
## Recipe B: the Checks API pattern (what a hosted Reticle would do)
|
|
45
49
|
|
|
46
50
|
Both providers expose the same shape, which is why this is one integration rather than two:
|
|
47
51
|
|
|
@@ -54,10 +58,10 @@ The flow is: receive the deploy webhook → `reticle verify <target_url>` → po
|
|
|
54
58
|
|
|
55
59
|
## Pair it with the local gate
|
|
56
60
|
|
|
57
|
-
The deploy check catches what reaches a preview. `reticle gate` catches it earlier
|
|
61
|
+
The deploy check catches what reaches a preview. `reticle gate` catches it earlier: an agent that edits a covered file cannot "finish" without re-verifying:
|
|
58
62
|
|
|
59
63
|
```bash
|
|
60
|
-
|
|
64
|
+
npx @reticlehq/server gate --since origin/main # exit 1 unless passing artifacts cover the affected flows
|
|
61
65
|
```
|
|
62
66
|
|
|
63
67
|
Use both: `gate` in the agent's Stop hook (see `agent-cheatsheet`), `verify` at the deploy. They read the same run artifacts, so a green gate locally and a green check on the PR mean the same thing.
|
|
@@ -66,4 +70,4 @@ Use both: `gate` in the agent's Stop hook (see `agent-cheatsheet`), `verify` at
|
|
|
66
70
|
|
|
67
71
|
- **`verify` needs one connected session.** If several tabs of the app are open against the same daemon it refuses rather than guessing which to drive.
|
|
68
72
|
- **It replays flows sequentially against one tab**, so flows must not depend on each other's leftover state (a flow that logs in contaminates the next one). Author self-contained flows, or use `reticle_flow_verify { parallel }`, which gives each flow an isolated context.
|
|
69
|
-
- **No saved flows means nothing to verify
|
|
73
|
+
- **No saved flows means nothing to verify.** `verify` fails rather than reporting a vacuous pass.
|