Closed 2bndy5 closed 1 year ago
The current fix I forgot to post is to use square brackets
subgraph cluster_rf24 {
graph [xref=":mod:`circuitpython_nrf24l01.rf24`"]
RF24 [xref=":class:`~circuitpython_nrf24l01.rf24.RF24`"]
}
I just found that this theme's graphviz ext will crash when an xref is not enclosed in a set of square brackets.
For example, the following code would work fine with the sphinx graphviz ext:
But if I change the subgraph's
tooltip
andlabel
attrs in favor of the newxref
attr:The dot executable complains about the comma syntax. Below is the code passed to the dot exe at docs' build time:
Problematic src
https://github.com/jbms/sphinx-immaterial/blob/a944f278cb7f1066482e59b9a17d3311624cd01e/sphinx_immaterial/graphviz.py#L53-L58Luckily, the dot syntax delimits by whitespace, so the
,
(or the older;
) delimiters are optional. See this test in the graphviz playground