prd.md
1.71 KB
The graphlemon planner workflow (task wirn7j2cp / run wf_4cc84f9e-a41) completed. It produced a PRD (no code/doc files were written — the PRD text itself is the deliverable) for fixing the "运行历史" (run history) click-navigation bug in the Graph console and adding a missing run-detail page.
Key points from the PRD:
- Problem: Clicking a row in
#gc_runs_listonly switches the task selector (onSwitchToTask) instead of opening a real run-detail view — a known, previously-accepted shortcut (per an existing code comment inapp.js:1524-1529) that this task is meant to close. - Scope:
- New hash route
#/runs/:run_idwith arenderRunDetail/mountRunDetailview, reusing existing DAG rendering (renderGraphVisualizerPanel) and log viewer (mountLogViewer, WS tail for live nodes / static fetch for terminal nodes) — no new visual components. - New backend query for a single run by
run_id(404 if missing), matching the node-field shape oftask_query.get_task's embedded runs so the frontend needs no remapping. - Fix the
#gc_runs_listclick handler to navigate to the new route instead of callingonSwitchToTask.
- New hash route
- Explicitly out of scope: no changes to the
GET /api/work-graph-runslist endpoint, no backend log-push changes, no multi-run comparison UI, no DAG visual redesign. - Acceptance criteria cover normal navigation, live vs. terminal-node log behavior, 404 handling, WS cleanup on navigation, and list-rendering being unaffected.
This matches the existing memory note (project_run_history_click_missing_detail_page.md) — the planner re-verified against current code and reached the same conclusion. Next step would normally be SDD refinement of the exact API/route shape, then Coder implementation.