feat(workflows): expose durable run history [issue:#2980] - #3903
feat(workflows): expose durable run history [issue:#2980]#3903tcballard wants to merge 2 commits into
Conversation
Signed-off-by: Tom Ballard <tom@armytage.co>
|
durable run history will help a lot for debugging workflows. can the list show a failed/cancelled badge without opening the run detail? |
Keep failed and cancelled statuses visible in collapsed run-history rows and cover both states with focused Desktop E2E evidence. Signed-off-by: Tom Ballard <tom@armytage.co>
|
The authoritative relay and Desktop run-history work is now merged in #5780: The remaining user-visible bug is in Would you prefer this PR be refreshed and reduced to a CLI adapter for the |

Summary
Implements workflow run history for #2980, as a separate contribution in the #3863 handoff workstream.
The current
workflows runspath queried lifecycle event kinds the relay does not emit, so it returned[]even when the durableworkflow_runstable contained failed or completed executions. Desktop had the same empty placeholder.Scope
Included
GET /api/workflows/{id}/runsrelay read path over the existing durableworkflow_runstable.execution_trace, timestamps, and failure diagnostics.Excluded
Product / Architecture Decisions
workflow_runsrecords directly instead of reconstructing partial state from event kinds46001–46003, which the relay does not emit.User-Facing Contract
CLI
buzz workflows runs --workflow <workflow-id> [--limit <n>]now returns a JSON array of durable run records. An empty array means that no records exist, rather than that lifecycle events were silently unavailable.Desktop
The existing workflow detail panel receives durable run records and renders status, execution trace, and error information from the relay. The Run History list shows
FAILEDandCANCELLEDbadges while rows remain collapsed, so debugging can begin without opening each run detail.Verification
Ran
cargo fmt --all -- --checkgit diff --checkcargo check -p buzz-relaycargo check -p buzz-clicargo clippy -p buzz-relay -- -D warningscargo clippy -p buzz-cli -- -D warningscargo test -p buzz-relay workflow_run_wire_preserves_failure_diagnostics --libpnpm --dir desktop exec biome check tests/e2e/workflow-run-status-badges.spec.ts src/features/workflows/ui/WorkflowDetailPanel.tsx src/testing/e2eBridge.ts tests/helpers/bridge.ts playwright.config.tspnpm --dir desktop build:e2eBUZZ_WORKFLOW_STATUS_SCREENSHOTS=1 pnpm --dir desktop exec playwright test tests/e2e/workflow-run-status-badges.spec.ts --project=smoke --reporter=lineCovered
The relay regression test verifies the wire conversion preserves failed status, trigger event ID, timestamps, per-step trace data, and the failure message.
The new Desktop regression test triggers failed and cancelled runs, collapses both rows, and verifies both badges remain visible without an open trace. Screenshot evidence is posted in a follow-up PR comment.
The Desktop Tauri check was attempted but this environment lacks
cmake, so the existingaudiopus_sysnative build cannot start. No desktop application shell redesign was added; the follow-up is limited to the existing workflow detail panel and its test fixture.Review Path
crates/buzz-relay/src/api/bridge.rsandrouter.rsNotes For Reviewer
This is intentionally separate from the other Buzz upstream handoff contributions and is not stacked on the Canvas revision-history PR. It does not merge or alter any OEXL settlement boundary.