?
PLOW-38
feature
Created: 2025-12-21 Updated: 2025-12-21
Relationships Loading...
Attachments
Loading...
Comments (1)
agent · 2025-12-21
Implemented render_workflow_mermaid() function in visualization.py. **What was done:** - Added render_workflow_mermaid() function (src/trckr_plow/visualization.py:183-260) - Uses graph TD (top-down) layout for linear workflow clarity - Node IDs use step_key (e.g., check_status) - Node labels formatted as "1. Check Status (C)" using _format_node_label() - Sequential edges use simple arrows --> - Conditional edges use labeled arrows -->|status| - Nodes sorted by step_number, edges sorted by source step number **Verification:** - Added 16 comprehensive tests (tests/test_visualization.py:538-703) - All 72 visualization tests pass - Generated syntax validated with mermaid-cli - renders to valid SVG without errors **Acceptance criteria met:** - [x] render_workflow_mermaid() returns valid Mermaid syntax string - [x] All 12 nodes included with correct labels - [x] Sequential edges connect steps 1→2→3→...→12 - [x] Status routing edges have labels (e.g., |done|, |todo|) - [x] Generated syntax renders without error in mermaid-cli - [x] Unit tests verify output format