Hi Everyone,
I made the graph with pydot library using "fdp" layout parameter and also giving position for each nodes for the graph. While converting the graph to xml, it is giving error as :
Traceback (most recent call last):
File ~\AppData\Local\anaconda\Lib\site-packages\IPython\core\interactiveshell.py:3505 in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
Cell In[160], line 3
xml = graphviz2drawio.convert(gdt)
File ~\AppData\Local\anaconda\Lib\site-packages\graphviz2drawio\graphviz2drawio.py:26 in convert
nodes, edges = SvgParser(svg_graph).get_nodes_and_edges()
File ~\AppData\Local\anaconda\Lib\site-packages\graphviz2drawio\models\SvgParser.py:14 in get_nodes_and_edges
root = ElementTree.fromstring(self.svg_data)[0]
File ~\AppData\Local\anaconda\Lib\xml\etree\ElementTree.py:1338 in XML
parser.feed(text)
File <string>
ParseError: not well-formed (invalid token): line 64, column 109
Some relevant code info is as follows which I find was different than usual standard code:
# Create an empty PyDot graph
G_pydot = pydot.Dot(graph_type='digraph',layout="fdp")
pydot_node = pydot.Node(str(node), label=item['text'],shape=get_shape(item['shape_type']),slane=key,pos=f"{X},{Y}!")
# Add the PyDot node to the PyDot graph
G_pydot.add_node(pydot_node)`
gdt=G_pydot.to_string()
xml = graphviz2drawio.convert(gdt)
Hi Everyone, I made the graph with pydot library using "fdp" layout parameter and also giving position for each nodes for the graph. While converting the graph to xml, it is giving error as :
Some relevant code info is as follows which I find was different than usual standard code: