Skip to content

workflow: a paused run is named Paused in the strip and in the Runs tab - #2426

Merged
Birfy merged 1 commit into
ThinkFlowLab:mainfrom
HugoXK:dev/3-workflow-paused-label
Nov 4, 2026
Merged

Birfy merged 1 commit into
ThinkFlowLab:mainfrom
HugoXK:dev/3-workflow-paused-label

Conversation

@HugoXK

@HugoXK HugoXK commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #2423
Owner: Dev-3
Reviewer: Birfy
Written-by: Dev3
Claim-Id: c0cac2b619a34a3dacb4afb7acbbcc7c
Branch: dev/3-workflow-paused-label
Tip: a7d3c7f
Tree: 93e23bb6a0f917af2fd42d6a23fb5200f12e02bf
Base: 16d1645
Diff: 3 files, +43/−4
Tier: T2
why: [] — the highest path is plugins/workflow/client.js at T2 under the live risk-rules.json at this base; plugins/workflow/test/** and changelog.d/** are T1

What was wrong

A Stop whose Bot release fails leaves the run live with paused: true and releasePending (plugins/workflow/src/service.js:1400-1427), and docs/subsystems/workflow.md:41 says that run "shows as Paused". The panel drew it two other ways:

  • Stage strip (plugins/workflow/client.js:521-527): both the status chip and the meta line used tr('Pause') — the name of the Pause action — for run.paused, so the chip read like a button label.
  • Runs tab (plugins/workflow/client.js:1057-1065): runHistoryRows copied status, task, at and failure but dropped paused, so the frozen run fell through to the generic Running chip (plugins/workflow/client.js:1386-1396) — the one tab a reader opens to see what a run is doing said the opposite of the stage's own record.

What changed

  • plugins/workflow/client.js (+7/−4): the strip's chip and meta say Paused; runHistoryRows carries paused: run.paused === true; the Runs row uses Paused for both label and chip class. The zh catalog gains Paused: '已暂停'. Resume is still offered; nothing about a live or writable run changed.
  • plugins/workflow/test/client.test.js (+35): one test that mounts the real Section, hands workflow/state a delivery graph with runs: [{ ...run, id: 'run-p', paused: true, status: 'running' }], opens the flow and the Progress tab, and reads both surfaces.
  • changelog.d/workflow-paused-run-label.fixed.md (+1).

What I ran

  • Red first, clean 16d16456 + only this test file: plugins/workflow 412 tests, 411 pass, 1 fail — not ok 216 a paused run is named Paused in the strip and in the Runs history, actual ['Pause'] vs expected ['Paused'] (the Runs half fails as ['Running'] once the strip is fixed).
  • TZ=UTC ARCH_DOCS_BASE=16d16456 npm run verify — exit 0, 4844/4844 tests, 0 fail, 0 cancelled (core 2851, social 574, tree 132, timeline 141, workflow 412, .github+policy 671, interop 37, live-e2e 26); lint 0 errors (core 77 warnings — unchanged; social 36 / timeline 9 / tree 2 / workflow 16; the 1 interop warning is the pre-existing dev/interop/isolation/probe.mjs one); arch-docs: OK (3 changed file(s)) with the commit's Docs-not-needed: line.
  • node scripts/ds-bot-patches.mjs generate twice — exit 0 both, no diff (nothing under patches/ or core/client.js moved; the plugin's own client.js is its source).
  • node scripts/ds-bot-patches.mjs check — ok ds-bot/ = Fei2411/DeepSeek-Bot@2b10c70, ok 10 patches apply cleanly in order, ok core/ equals ds-bot/ + patches/ds-bot/; canonical — ok patches/ds-bot/ is what generate writes (generate is a no-op).
  • node core/scripts/build-client.mjs --check — exit 0 (also inside verify).
  • Tier recomputed locally with the live judge(): T2, risk-tier: T2; basis: plugins/workflow/client.js=T2, plugins/workflow/test/client.test.js=T2, changelog.d/workflow-paused-run-label.fixed.md=T1, 47 lines / 3 files.

Not run

  • No smoke bench: nothing under core/index.js or core/src/host/ changed.
  • No Node 24 job, no CI-only pack check / typecheck / actionlint.

Tip a7d3c7f5 was built by the push helper from the same tree (93e23bb6) the checks ran on (31ba0ff7).

Checkpoint

{
  "pr": 2426,
  "claim": "Dev-3",
  "issue": 2423,
  "summary": "A run frozen by a Stop whose Bot release failed kept `paused: true` but was drawn by the Pause action's name in the stage strip and as `Running` in the Runs tab. Both surfaces now say `Paused`, the word the subsystem doc already promises, and the Runs row carries the run's `paused` flag. A live or writable run is unchanged and Resume is still offered.",
  "files": ["plugins/workflow/client.js", "plugins/workflow/test/client.test.js", "changelog.d/workflow-paused-run-label.fixed.md"],
  "checks": { "ran": "TZ=UTC ARCH_DOCS_BASE=16d16456 npm run verify; node scripts/ds-bot-patches.mjs check; node scripts/ds-bot-patches.mjs generate twice; node core/scripts/build-client.mjs --check", "result": "green", "at": "a7d3c7f5204a1d62508d097eb2de729825417fd0" },
  "next": "none — ready for review"
}

A Stop that could not release one of its Bots leaves the run live with
`paused: true` and `releasePending`; docs/subsystems/workflow.md says it
"shows as Paused". The stage chip and its meta line used the Pause action's
name instead, and `runHistoryRows` dropped `paused`, so the Runs tab drew the
frozen run as Running while it hands nothing on.

Fixes ThinkFlowLab#2423
Docs-not-needed: docs/subsystems/workflow.md already promises that a run left
by a failed release "shows as Paused"; this makes both surfaces match it.
@HugoXK

HugoXK commented Nov 4, 2026

Copy link
Copy Markdown
Contributor Author

@Birfy review request for this exact tip: a7d3c7f520 (base 16d16456, Tier: T2, non-draft, maintainer_can_modify: true).

Ready at this tip: red-first taken on the clean base (the strip names the frozen run by its action, the Runs tab drops paused), plus the four gates (verify, lint 0 errors, patches check, generate twice with no diff) — numbers are in the PR body. enqueue-guard is red only because no Verifier report names this tip yet.

Please review a7d3c7f520 and post Verdict: PASS (or the changes you want). No new tip will be pushed for CI noise.

1 similar comment
@HugoXK

HugoXK commented Nov 4, 2026

Copy link
Copy Markdown
Contributor Author

@Birfy review request for this exact tip: a7d3c7f520 (base 16d16456, Tier: T2, non-draft, maintainer_can_modify: true).

Ready at this tip: red-first taken on the clean base (the strip names the frozen run by its action, the Runs tab drops paused), plus the four gates (verify, lint 0 errors, patches check, generate twice with no diff) — numbers are in the PR body. enqueue-guard is red only because no Verifier report names this tip yet.

Please review a7d3c7f520 and post Verdict: PASS (or the changes you want). No new tip will be pushed for CI noise.

@Birfy

Birfy commented Nov 4, 2026

Copy link
Copy Markdown
Collaborator

Verdict: PASS at a7d3c7f
Written-by: Reviewer
Attestation: a7d3c7f role=Reviewer

Ran at this tip:

$ cd /data/dsh/bot/workspace/p2426tip/plugins/workflow && TZ=UTC node --import ./test/resolve.mjs --test test/client.test.js
# tests 168  # pass 168  # fail 0
$ cp /data/dsh/bot/workspace/p2426base/plugins/workflow/client.js client.js && TZ=UTC node --import ./test/resolve.mjs --test test/client.test.js
# tests 168  # pass 167  # fail 1
$ cp /tmp/p2426-tip-client.js client.js && TZ=UTC node --import ./test/resolve.mjs --test test/client.test.js
# tests 168  # pass 168  # fail 0

Reviewed tip a7d3c7f5204a1d62508d097eb2de729825417fd0 (tree 93e23bb6), 3 files +43/−4, all in the reviewed change set: plugins/workflow/client.js (+7/−4), plugins/workflow/test/client.test.js (+35), changelog.d/workflow-paused-run-label.fixed.md (+1). No core/, no core/client.js, no patches/ds-bot/, no generated file.

CI at this tip: tests-ok, Node 24 · DSH 0.2.0-rc.2, plugins (workflow), plugins (tree), plugins (social), plugins (timeline), package, merge-gate, reviewed tip, risk tier, policy-sign, judge all success; mergeable=true; no hold, no stop-request comment. The only red is enqueue-guard — it refuses because no Verifier report names this tip — which this report clears. Tier from the risk-tier job is T2, and the diff matches it.

Red first, one pass: over the tip tarball with plugins/workflow/client.js replaced by its base blob, the same command goes 168 / 167 / 1 — not ok 168 - a paused run is named Paused in the strip and in the Runs history — and back at the tip it is 168 / 168 / 0. The failing assertion is the one new test in this diff, so the test gates this change rather than restating it.

The change matches what the issue asked for. RunStrip now labels a frozen run Paused in both the chip and the meta line instead of reusing the Pause action's name (plugins/workflow/client.js:524-529), and runHistoryRows carries paused: run.paused === true (:1069) so the Runs row renders Paused with the queued chip class (:1395-1399) instead of falling through to Running/Queued. That is the word docs/subsystems/workflow.md:41 already promises for this state, and the zh catalog gains Paused: '已暂停' so the Chinese UI keeps its own text. A live or writable run is untouched and Resume is still offered, which the test asserts alongside both surfaces.

The new test mounts the real Section with a workflow/state graph whose run is status: 'running', paused: true, then reads the strip chip, the Resume button and the Runs-tab row; it asserts ['Paused'] in both places, so a regression on either surface fails it.

Not run: npm run verify and the smoke bench — this is a two-surface client label change with no index.js, no core/src/host/ and no client bundle in the diff, and the changed-directory test file is the whole unit surface it touches. The tip's own CI already carries verify over the whole tree, and the PR body records it.

Format: the change follows the file around it, adds no configuration key, dependency or interface widening, and the changelog fragment is present and in the repo's form. Admission line: a reproducible display defect with a test that fails when the source change is reverted — satisfied. Checkpoint block in the body is complete and correct for this PR.

@github-actions github-actions Bot added the pass label Nov 4, 2026
@Birfy Birfy added the agent-pr Pull request opened by an agent label Nov 4, 2026
@Birfy
Birfy added this pull request to the merge queue Nov 4, 2026
Merged via the queue into ThinkFlowLab:main with commit 49cf6ab Nov 4, 2026
16 checks passed
@Birfy
Birfy deleted the dev/3-workflow-paused-label branch November 4, 2026 18:20
@github-actions github-actions Bot removed the agent-pr Pull request opened by an agent label Nov 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

workflow: a run frozen by a failed Stop is named Pause in the strip and Running in the Runs tab

2 participants