I'm working with python and I created a custom class with a draw method which returns a graphviz.Digraph object. Inside a Jupyter Notebook, when trying to render this object using VSCode built-in renderer, I get wrong results, specifically in the text written over the edges.
I tried to render the object both directly (putting the object as last line of the cell) and indirectly, first producing an .svg file and then displaying it with IPython.display.SVG():
direct rendering
indirect rendering
Opening the aforementioned file with other programs, like any browser, gives correct results.
Also running the notebook in JupyterLab gives correct results. I couldn't load the .svg file directly in this post, thus you can find it at this link
The fact that wrong results are produced even in the indirect method makes me suppose that the problem lies in the way VSCode renders SVG files, but I lack knowledge to solve this issue.