Merge branch 'main' into web-search
# Conflicts: # web/src/app.js # web/src/protocol.js # web/src/repository.js # web/styles.css # web/test/repository.test.mjs # web/test/ui-smoke.mjs
This commit is contained in:
+15
-4
@@ -41,10 +41,10 @@ Status legend: `todo` · `partial` (some of it works) · `done` (working + captu
|
||||
| R8 | Artifacts gallery + full-screen viewer (images inline, others download/open) | `GET /artifacts/…` | done (captured 2026-10-19: `captures/04-run-430-artifacts.png`, `captures/05-artifact-viewer.png`) |
|
||||
| R9 | Session export link (read-only `session.html`) | `GET /artifacts/…` | done (captured 2026-10-19: `captures/06-session-export-link.png`) |
|
||||
| R10 | Live run updates: subscribe/unsubscribe + event fold | `subscribe`, `unsubscribe`, `run_event` | todo |
|
||||
| R11 | Human decision sheet: prompt, options, feedback | `decide_run` | todo |
|
||||
| R12 | Cancel run | `cancel_run` | todo |
|
||||
| R13 | Retry failed stage (resume) / restart from start | `retry_run` | todo |
|
||||
| R14 | Rename a run | `set_run_title` | todo |
|
||||
| R11 | Human decision sheet: prompt, options, feedback | `decide_run` | partial — the pure model (`src/actions.js`: `pendingDecision`, `lastWaitingStep`, `waitingPrompt`/`waitingOptions`, `humanOptions`, `decisionTargetLabel`, `DecisionDraft`) and the card + sheet are implemented with the Android copy verbatim: card title `Waiting for your decision`, meta `{stage} · run {id} · {runLabel}`, action `Decide`; sheet title `Decide {stage}`, meta `run {id} · {runLabel}`, the recorded instructions verbatim when non-blank, one selectable row per option in author order showing the option and `→ {target}` only when the declared edge resolves, the `Feedback (optional)` field, and `Cancel` / `Confirm decision` (reading `Sending…` while in flight). Selecting a row sends nothing and Confirm is disabled until a non-blank option is chosen; a refusal keeps the sheet open with the server's exact reason and re-reads the run. The request shape is unit-tested (`decide_run` = `{type, run_id, option, stage?, feedback?}`, stage/feedback omitted when blank, feedback trimmed). **No browser capture yet**: the live server had no `waiting` run when `ui-smoke.mjs` ran (only executing/failed/finished runs), so this row stays `partial`; `test/ui-smoke.mjs` now captures the card, the sheet and the selected state automatically (`captures/41-run-<id>-decision-card.png`, `captures/42-run-<id>-decision-sheet.png`, `captures/43-run-<id>-decision-selected.png`) the moment a waiting run exists |
|
||||
| R12 | Cancel run | `cancel_run` | done — `src/actions.js` `canCancel` offers a `Cancel run` action only while the run is `executing`; the confirm dialog is the Android copy verbatim (title `Cancel run {id}?`, `This asks the server to stop the active run.`, confirm `Cancel run`, dismiss `Keep`), and the request is exactly `{type:'cancel_run',run_id}` followed by a silent `get_run` refresh (unit-tested in `test/repository.test.mjs`). Captured `captures/40-run-459-cancel-confirm.png` on the executing run present at capture time. **Shown, not executed**: the only candidate was another live pipeline's executing run, so the dialog was shown and dismissed with `Keep` — no `cancel_run` was sent (a real cancel is only safe against a run started in a scratch workspace, which this stage did not do) |
|
||||
| R13 | Retry failed stage (resume) / restart from start | `retry_run` | done — `canRetry` is true only for a loaded, non-executing, `failed` run; the Retry confirm is the Android copy verbatim (title `Retry run {id}?`, `Only failed runs can be retried. The server starts a new run from the same input.`, confirm `Retry`, dismiss `Keep`) and the default send carries only `run_id` + a fresh `request_key` (**no** `retry_mode`, so the server's `resume` default applies exactly like the Android client's mode-less call; unit-tested). Captured `captures/35-run-440-run-actions.png` (failed run 440 offers Retry and no Cancel) and `captures/36-run-440-retry-confirm.png`. **Divergence from the Android UI, stated here**: Android exposes resume only while the protocol has both modes, so the browser adds a clearly-labelled secondary `Restart from start` confirm that states it `replays the whole pipeline from the start instead of resuming the failed stage` and sends `retry_mode:"restart"` (`captures/37-run-440-restart-confirm.png`). Both dialogs were shown and dismissed with `Keep`; no run was started |
|
||||
| R14 | Rename a run | `set_run_title` | done — an inline field on the Summary title row (pre-filled with the current title, `Rename` / `Save` / `Cancel`) sending exactly `{type:'set_run_title',run_id,title}` and then refreshing the run and the runs-list row (unit-tested). Captured `captures/38-run-440-rename-field.png`. The one shared `Action failed` dialog was exercised by a real refused rename: `captures/39-run-440-action-failed.png` shows the live server's exact reason `a title with usable text is required` (a blank title mutates nothing). **Divergence from the Android UI, stated here**: Android does not surface `set_run_title` at all (its README records the deliberate omission), so this control is browser-only |
|
||||
| R15 | Attention / "Needs you" surface: counts, open, individual dismiss, clear all | derived from `list_runs` + run events | todo |
|
||||
|
||||
Two wording decisions in R3's stage pane, recorded here as the app-authoritative
|
||||
@@ -62,6 +62,17 @@ empty-capture variants carry the `Changes · ` prefix — while the expanded bod
|
||||
own summary line repeats the count and stat. The header is rendered verbatim, not
|
||||
re-composed.
|
||||
|
||||
R11–R14 share one `Action failed` dialog (title `Action failed`, the server's own
|
||||
message, a single `OK`), matching `RunDetailScreen.kt`; every server string is set
|
||||
with `textContent`, never `innerHTML`. Where a live action was unsafe this stage
|
||||
says so rather than mutating shared state: the R12 cancel and the R13 retry/restart
|
||||
sends were shown and dismissed with `Keep` (never executed), and R11 has no live
|
||||
capture because the server had no waiting run. The request shapes for all four are
|
||||
unit-tested in `test/repository.test.mjs` and the model in `test/actions.test.mjs`;
|
||||
`test/ui-smoke.mjs` captures the rendered dialogs, the rename field, the refused
|
||||
rename's exact server reason and — when a waiting run exists — the decision
|
||||
card/sheet.
|
||||
|
||||
## Search
|
||||
| # | Feature | Protocol | Status |
|
||||
| --- | --- | --- | --- |
|
||||
|
||||
Reference in New Issue
Block a user