Repository navigation
Description
Bug: Back navigation retargets an open automation Stop confirmation
Priority: P2.
Reproduce
- Have run B then run A of the same automation as consecutive browser-history entries, with B’s detail data available from the preceding visit.
- While viewing A, click Stop the run. The confirmation says “Stop this run?” and warns that it cannot be resumed. Do not confirm yet.
- Use browser Back. The replay uses the actual TanStack memory-history
back()operation, with no direct component rerender. The route changes to run B while the same confirmation remains open. - Confirm Stop the run. The mutation payload is
{ organizationId: 'audit-org', runId: 'B' }, even though the user opened the confirmation on A.
Expected: A confirmation records the run for which it was opened, or closes when the run identity changes. It must not silently acquire a different destructive target.
Root and controls
services/platform/app/features/automations/components/run-detail.tsx:95 keeps only a boolean confirmStop. The ConfirmDialog at lines 251–270 stays open across a runId prop change and reads the current runId in onConfirm at line 263. Both organization and project run route components render RunDetail without an identity key; the app router supplies no remount dependency.
The normal A confirmation control sends only run A. The navigation case checks that there were no mutation calls before confirming and then observes exactly the B payload. No real run was stopped. Screenshot: stop-back-retarget.png. Log case: stop-back-retarget.
Dedup
Baseline 102, additional ledger (106 at final snapshot), 256 all-state automation-related issues and targeted live Stop/navigation searches reviewed. No matching report found. #3677 is reporting success when sandbox cancellation fails, #3738 is a task-status/subtask choreography refusal, and #3721 is stale approval-refusal text; none concerns a confirmation changing its mutation target after route navigation.
Source SHA: 9ea59724df24d62729a9360f3902d964dab39b3e. Classification: local exploratory review, no product changes.
Replay from /Users/yannick/Documents/git/tale/services/platform:
bunx vitest --config /Users/yannick/.codex/notes/tale-1000-additional/automations-functional-next/vitest.browser.config.ts run run-state.browser.test.tsx --reporter verboseFinal result: exit 0, 9/9 observation/control cases passed. Test assertions record observed defective behavior; this is not a claim that product regression tests are green after a fix. Test source: run-state.browser.test.tsx. Log: run-state.replay.log.
Limits: Actual Chromium, RunDetail, RunAskCard, QuestionFlow, shared fields/dialog, i18n providers and TanStack Router execute. The minimal route wrapper reproduces the shipped route shape and useParams-to-RunDetail wiring; the authenticated shell and generated route tree are omitted. Query and mutation hooks are fixture seams, graph/inspector/log/import-continuation rendering is stubbed, and the memory-history entries are synthetic. Reads are immediately available cached-style snapshots; the same-run replacement is a synthetic reactive data update, not a running agent. Mutation spies record intended payloads only. No backend, database, provider, production, real stop, or real answer operation ran. The screenshots omit application CSS and prove DOM/content state only, not visual styling. Existing Vitest 4.1.11 / browser 4.1.10 emits a version warning; all final cases pass without hook errors.
Independent parent verification
Parent inspected the real route wrappers, router remount configuration, RunDetail, RunAskCard and question-flow state, reviewed all probe seams and dedup comparisons, and independently reran all nine Chromium cases. All passed with exit 0 (parent-browser.log). The same-ask refresh and fresh-target controls distinguish lost identity from ordinary draft preservation. No native cancel/answer action or real agent execution was attempted.
Activity
yannickmonney commentedon Sep 29, 2026
Current-main revalidation at
b7f8ca02ec249c004652b1ee52e112d9cdfa53ea: the reported defect still reproduces.The actual router Back operation still retains the Stop dialog and retargets its captured cancellation request to B. The ordinary A confirmation control passed. The complete run-state replay passed 9/9 Chromium cases.
The parent reran the local evidence against an isolated detached current-main checkout with current workspace source. Query/mutation boundaries remain controlled; no real cancellation, deletion, assignment, production test or provider action occurred. The original pinned-source evidence is retained. This revalidation does not add a finding.
tale-code-bot commentedon Oct 30, 2026
Already done on
main, so the Development board's task for this issue (TALE-40) is cancelled and the issue closed as completed.Evidence:
4a77db7841d1681f72501e94174f3f21e02b5931, "fix(platform): recover automation run detail read failures" (fix(platform): recover automation run detail read failures #4288, 2026-10-05), is onmainb2560c2d7d3294993e66129c891be4a059f3d6c4.<RunDetailBody key={props.runId} …/>inservices/platform/app/features/automations/components/run-detail.tsx, with theconfirmStopstate inside that body.If something is still missing, reopen this issue and say what.