You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
get clicking dismiss on a run row in /?section=overview in the console web ui to remove the row from view faster #2302
Make clicking Dismiss on a one-line run row in the Console Inbox (/?section=overview) remove that row from view immediately, instead of after the save and refresh complete, so the user no longer wonders whether it worked.
Diagnosis (confirmed from code)
In console.js, the form[data-dismiss] submit handler sets the Dismissing… pending state, then awaits fetch(form.action, …) (lines 526–529) and, on success, await refresh() (line 542). The row is only removed when that refresh's server HTML is morphed into #inbox by morph() (line 67). Removal therefore waits for: the server mutation, the POST response, and a second full Inbox page fetch plus morph. For HTML form posts the POST also follows the redirect in dismiss.rs, whose body the script discards.
The server mutation itself (dismiss::request in dismiss.rs) snapshots the user's records, evaluates the Inbox, writes the *.dismiss.json file and cleans retained scratch (crate::scratch::dismiss), so the round trip is not trivial.
Current feedback is only the Dismissing… text and a disabled button via showDismissal() (console.js); the row itself, the thing the user acted on, stays on screen. Glossary: a Dismissal takes a row out of Needs you or Ready for review (GLOSSARY.md); in Overview the dismissed row later reappears under Done via the refresh, folded by default (folds.js).
Required change
In the same submit handler, for an inline row Dismiss (row && !undo): remove (or hide) the row immediately on submit, before awaiting the POST, and move selection/focus to the next visible row as the current success path does (lines 533–537). The d keyboard path submits the same form, so it gets this for free.
Preserve server truth: keep the existing dismissals pending map and duplicate-submit guard; on success keep showing the Dismissed <subject> · Undo notice and still run the existing refresh() so counts, section placement (Done/Resolved) and other tabs reconcile.
On failure: restore the row (at its prior position where practical) with the existing inline error Could not save the dismissal: … on its form, button re-enabled, no dismissal notice. The existing held-request and 409 tests in inbox.test.cjs define this feedback contract.
Guard the race with live updates: a refresh()/morph that lands while the Dismiss request is still in flight must not resurrect the optimistically removed row before the request settles; after a failed request the normal server-rendered row must be able to return.
Scope: inline Inbox rows only (including fleet rows, which carry the machine hidden input in row.html). Do not change Peek (#peek-content) Dismiss/Undo behaviour, the no-JavaScript form post + redirect fallback, src/logs/dismiss.rs persistence semantics, or Undo behaviour beyond keeping its current pending/error feedback.
Tests and docs
Extend console/tests/inbox.test.cjs: with /dismiss held by a route promise (pattern already used at lines 1229–1250), assert the row is gone from view before the request is released, then release and assert the Undo notice and reconciled row; with /dismiss fulfilled as 409, assert the row is restored with the error and an enabled button. Existing dismissal tests (keyboard d, notice Undo, failed Dismiss retry, Peek pending) must keep passing: node --test console/tests/inbox.test.cjs (after building, per console/tests/playwright.cjs setup).
Update the Dismiss paragraph in console/README.md to state the row leaves view immediately and returns if the save fails.
Out of scope: speeding up the server mutation or dropping the post-save refresh; optimistic removal alone fixes the perceived delay.
Activity
JacobStephens2 commentedon Nov 19, 2026
Agent Brief
Make clicking Dismiss on a one-line run row in the Console Inbox (
/?section=overview) remove that row from view immediately, instead of after the save and refresh complete, so the user no longer wonders whether it worked.Diagnosis (confirmed from code)
form[data-dismiss]submit handler sets theDismissing…pending state, thenawaitsfetch(form.action, …)(lines 526–529) and, on success,await refresh()(line 542). The row is only removed when that refresh's server HTML is morphed into#inboxbymorph()(line 67). Removal therefore waits for: the server mutation, the POST response, and a second full Inbox page fetch plus morph. For HTML form posts the POST also follows the redirect in dismiss.rs, whose body the script discards.dismiss::requestin dismiss.rs) snapshots the user's records, evaluates the Inbox, writes the*.dismiss.jsonfile and cleans retained scratch (crate::scratch::dismiss), so the round trip is not trivial.Dismissing…text and a disabled button viashowDismissal()(console.js); the row itself, the thing the user acted on, stays on screen. Glossary: a Dismissal takes a row out of Needs you or Ready for review (GLOSSARY.md); in Overview the dismissed row later reappears under Done via the refresh, folded by default (folds.js).Required change
row && !undo): remove (or hide) the row immediately on submit, before awaiting the POST, and move selection/focus to the next visible row as the current success path does (lines 533–537). Thedkeyboard path submits the same form, so it gets this for free.dismissalspending map and duplicate-submit guard; on success keep showing theDismissed <subject> · Undonotice and still run the existingrefresh()so counts, section placement (Done/Resolved) and other tabs reconcile.Could not save the dismissal: …on its form, button re-enabled, no dismissal notice. The existing held-request and 409 tests in inbox.test.cjs define this feedback contract.refresh()/morph that lands while the Dismiss request is still in flight must not resurrect the optimistically removed row before the request settles; after a failed request the normal server-rendered row must be able to return.machinehidden input in row.html). Do not change Peek (#peek-content) Dismiss/Undo behaviour, the no-JavaScript form post + redirect fallback,src/logs/dismiss.rspersistence semantics, or Undo behaviour beyond keeping its current pending/error feedback.Tests and docs
console/tests/inbox.test.cjs: with/dismissheld by a route promise (pattern already used at lines 1229–1250), assert the row is gone from view before the request is released, then release and assert the Undo notice and reconciled row; with/dismissfulfilled as 409, assert the row is restored with the error and an enabled button. Existing dismissal tests (keyboardd, notice Undo, failed Dismiss retry, Peek pending) must keep passing:node --test console/tests/inbox.test.cjs(after building, perconsole/tests/playwright.cjssetup).