Highlights
TerraVision now generates .drawio files natively using Python's built-in xml.etree.ElementTree — no more pygraphviz C-extension compilation, no platform-specific workarounds, no [drawio] optional dependency. draw.io export works out of the box on all platforms.
What's New
Native draw.io emitter (issue #188)
- Replaced the
graphviz2drawiolibrary with a pure-Python mxGraph XML emitter - Uses draw.io's built-in AWS4 stencil shapes with correct fill colors per service category
- Uses draw.io's built-in Azure SVG image paths (
img/lib/azure2/) - GCP icons embedded as base64 PNGs from TerraVision's local icon library
Improved edge routing
- Edges now use draw.io's native
orthogonalEdgeStylerouting instead of Graphviz spline waypoints - Eliminates edges crossing through containers
Auto-generated shape mappings
_CLASS_TO_ALIASmap auto-generated at runtime fromresource_classes/(~850 entries)- Shape map generator updated to fetch
Sidebar-AWS4.js(authoritative source) for AWS shapes - Azure shape maps use
img/lib/azure2/SVG paths instead of legacy stencil XML
Breaking Changes
- Removed
graphviz2drawiodependency — no longer needed - Removed
[drawio]optional install group frompyproject.toml - Removed
drawio_shape_map_gcp.py— GCP uses embedded PNGs, not draw.io stencils
Installation
draw.io export now requires zero extra setup:
pip install terravision
terravision draw --source ./terraform --format drawio --outfile my-diagramThe previous platform-specific workarounds (Apple Silicon compiler flags, Windows Graphviz paths) are no longer needed.