fix: pipeline DAG renders as text — single-quote x-data JS comment#137
Merged
Conversation
…ext) A JS comment inside the parent #pipeline-dag Alpine x-data attribute used double quotes (`"no online agent"`). The attribute is opened with `"`, so the browser terminated it at the first inner `"` and dumped the rest of the Alpine `nodes` getter into the page as visible text (Phase-40 fingerprint_scan comment). Switch the comment to single quotes and add a regression guard (test_xdata_getter_has_no_unescaped_double_quotes) that asserts the #pipeline-dag x-data attribute value contains zero literal double-quotes. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
… STATE) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
SimplicityGuy
added a commit
that referenced
this pull request
Jun 15, 2026
Patch release: pipeline DAG dashboard rendering fix. - #137 single-quote the x-data JS comment so the pipeline DAG renders as a graph instead of dumping the Alpine `nodes` getter into the page as text (Phase-40 `fingerprint_scan` comment regression), + regression guard. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The live pipeline dashboard rendered the entire Alpine
nodesgetter expression as visible page text instead of the graph (reported on the homelab UI).Root cause: in
src/phaze/templates/pipeline/partials/dag_canvas.html, a JS comment inside the parent#pipeline-dagx-data="..."attribute used double quotes:// where 0 == "no online agent" (fail-safe default). NO stage_controls ...The
x-dataattribute is opened with", so the browser ends the attribute at the first"of"no online agent"and spills the rest of the getter (fingerprint_scan → proposals → scrape → match →}; } }">) into the DOM as text. Introduced in Phase 40 (thefingerprint_scannode comment).Fix
"no online agent"→'no online agent'. The getter otherwise uses single quotes for every JS string, so this restores a single well-formed attribute.test_xdata_getter_has_no_unescaped_double_quotesthat extracts the#pipeline-dagx-dataattribute value and asserts it contains zero literal"characters.No layout change —
NODE_LAYOUT/EDGES/ canvas dimensions are untouched.Verification
0double-quotes on the fix,2if the bug is reintroduced.uv run pytest tests/test_dag_canvas_render.py→ 30 non-DB tests pass (the 4test_integration_*errors are absent local Postgres only).pre-commit run --files ...→ all hooks clean.🤖 Generated with Claude Code