Repository navigation
v8.1.0
Phase T migration. Every diagram on the docs site (L2 topology /
dataflow / hand-authored conceptual .dot files) now renders
client-side via @hpcc-js/wasm-graphviz. The build-time
graphviz/dot system binary requirement is gone — apt-get install graphviz deleted from every CI / Release / Pages
runner.
What changed
common/handbook/diagrams.py: everyrender_*helper now
returns a graphviz DOT source string (viaDigraph().source)
instead of pre-rendered SVG. Reuses the existing
_build_*_graphbuilders untouched — only the output shape
changed._to_svg(the.pipe(format='svg')shellout helper)
is gone.main.py: thediagram(...)mkdocs-macro emits
<figure class="qs-diagram"><script type="text/x-graphviz">DOT</script></figure>
for every diagram. The figure wrapper keeps the existing
qs-lightbox.jsclick-to-zoom working unchanged.stylesheets/qs-graphviz-wasm.js: ~50-line client-side
bootstrap. Finds every<script type="text/x-graphviz">block
on page load, dynamically imports@hpcc-js/wasm-graphviz1.x
from jsDelivr (+esm), runsg.dot(source)against each, and
replaces the script tag with the rendered SVG..github/workflows/{ci,release,pages}.yml: 5 instances of
apt-get install -y graphvizremoved.pyproject.toml:graphviz>=0.20Python lib stays as a
[docs]dep — it's still constructing DOT source strings — but
the comment explicitly notes the system binary is no longer
required.tests/docs/test_handbook_diagrams.py: assertions updated
to validate the DOT shape (digraph {...}syntax, expected
node labels, expected edge counts) instead of SVG content.
Why this exists
Pre-Phase-T, every CI / Release / Pages job needed
graphviz/dot installed (a system package, not a Python wheel)
to build the docs site. New integrators hit the same wall on
their laptops. Phase S spiked two browser-rendered alternatives —
Mermaid + ELK and graphviz WASM — and concluded that
@hpcc-js/wasm-graphviz produces byte-identical layouts to the
build-time dot (it IS graphviz, just compiled to WASM and run
client-side). Mermaid + ELK lost on layout fidelity; the spike
findings live in PLAN.md § Phase S.
Compatibility
No CLI / Python API changes. The quicksight-gen docs apply
verb still emits a static site; the only difference is the site
no longer requires dot at build time. Diagrams render on
first page-load via the WASM bundle (~800kB, cached by the
browser after first hit).
Limitations + follow-ups
- Diagrams now require JavaScript to render; static-export
consumers (PDF / printed docs) won't get them. Open follow-up
if this becomes a real ask. qs-graphviz-wasm.jsCDN-loads from jsDelivr. Vendoring the
WASM lib intodocs/_static/for offline-friendly deploys is
queued as PLAN.md T.7 — defer if jsDelivr's reliability is
acceptable for the demo audience.