Fix DAG visualization and step link handling

- Handle dict inputs ({"node": "id"}) when building DAG edges
- Add normalize_inputs() to convert dict inputs to node IDs for steps
- Fix _parse_inputs to use _json.loads (correct import alias)
- Add SOURCE/EFFECT/SEQUENCE colors to node color maps

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
gilesb
2026-01-12 00:05:50 +00:00
parent 7a4cd3d413
commit 5c3558e1ba
2 changed files with 58 additions and 21 deletions

View File

@@ -1159,11 +1159,11 @@ def _parse_inputs(inputs_value):
return inputs_value
if isinstance(inputs_value, str):
try:
parsed = json.loads(inputs_value)
parsed = _json.loads(inputs_value)
if isinstance(parsed, list):
return parsed
return []
except (json.JSONDecodeError, TypeError):
except (_json.JSONDecodeError, TypeError):
return []
return []