Assertion error when using `dot` in `ortho.c` in `convertSPtoRoute` in graphviz 2.47.2 (not an issue in graphviz 2.46.1)
As folks here may already know, diagrams (https://diagrams.mingrammer.com/), a python package, uses graphviz.
I have been trying out the examples on https://diagrams.mingrammer.com/docs/getting-started/examples and when I try grouped workers and any diagram which groups nodes, I get the assertion error on ortho.c
:
Assertion failed: (sz >= 2), function convertSPtoRoute, file ortho.c, line 155.
[1] 23017 abort dot -Tpng grouped_workers
I ran dot
separately with the dot file that diagrams
created and I attach below what I see in verbose mode:
$ dot -v -Tpng grouped_workers
dot - graphviz version 2.47.2 (20210527.0053)
Using render: cairo:cairo
Using device: png:cairo:cairo
libdir = "/usr/local/Cellar/graphviz/2.47.2/lib/graphviz"
Activated plugin library: libgvplugin_dot_layout.6.dylib
Using layout: dot:dot_layout
The plugin configuration file:
/usr/local/Cellar/graphviz/2.47.2/lib/graphviz/config6
was successfully loaded.
render : cairo dot dot_json fig gd json json0 map mp pic pov ps quartz svg tk visio vml vrml xdot xdot_json
layout : circo dot fdp neato nop nop1 nop2 osage patchwork sfdp twopi
textlayout : textlayout
device : bmp canon cgimage cmap cmapx cmapx_np dot dot_json eps exr fig gd gd2 gif gv icns ico imap imap_np ismap jp2 jpe jpeg jpg json json0 mp pct pdf pic pict plain plain-ext png pov ps ps2 psd sgi svg svgz tga tif tiff tk vdx vml vmlz vrml wbmp webp xdot xdot1.2 xdot1.4 xdot_json
loadimage : (lib) bmp eps gd gd2 gif jpe jpeg jpg pdf png ps svg webp xbm
fontname: "Sans-Serif" resolved to: (PangoCairoCoreTextFont) "Helvetica"
pack info:
mode undefined
size 0
flags 0
margin 8
pack info:
mode node
size 0
flags 0
network simplex: 7 nodes 10 edges maxiter=2147483647 balance=1
network simplex: 7 nodes 10 edges 0 iter 0.00 sec
Maxrank = 2, minrank = 0
mincross: pass 0 iter 0 trying 0 cur_cross 0 best_cross 0
mincross Grouped Workers: 0 crossings, 0.00 secs.
network simplex: 17 nodes 24 edges maxiter=2147483647 balance=2
network simplex: 17 nodes 24 edges 4 iter 0.00 sec
Assertion failed: (sz >= 2), function convertSPtoRoute, file ortho.c, line 155.
[1] 23022 abort dot -v -Tpng grouped_workers
I am wondering if there is a fix at this point, because this is show stopping for us.
I am trying to get this working on a Mac OS X 11.3.1 with xcode installed. Any help is appreciated.
Last, here's the diagrams
python code I am working on in this case is the first example in https://diagrams.mingrammer.com/docs/getting-started/examples.
Steps to reproduce
- Download graphviz 2.47.2 (brew install graphviz).
- Download diagrams from https://diagrams.mingrammer.com/ using pip3.9 (pip3.9 install diagrams).
- Run the first example in https://diagrams.mingrammer.com/docs/getting-started/examples titled "grouped workers" using Python 3.9.
The dot file parsing fails with the above assertion error.
Expected Behaviour
The png file for the grouped workers is created.
Actual Behaviour
Assertion failed: (sz >= 2), function convertSPtoRoute, file ortho.c, line 155.
[1] 23022 abort dot -v -Tpng grouped_workers
OS Version
Mac OS X 11.3.1
Graphviz Version
2.47.2
Additional info
Workaround
- Uninstall diagrams: pip3.9 uninstall diagrams
- Uninstall graphviz: brew uninstall graphviz
- Download the source for graphviz 2.46.1 from the graphviz website and then compile and install it for my Mac OS X 11.3.1.