I'm trying to use the pydot.Dot.write_png(...)
with pydot and it fails to locate graphviz.
I've tried countless number of approaches/fixes to this problem, but they all seem to be for older versions of pydot and graphviz and are not working in my case. I'm running a windows 10 and here are the approaches i tried -
Approach 1) Setting the path in the systems environment variables and then restarting system/pycharm. Screenshot -
PS- I've added these to both, system variables and user variables. Also, the graphiz version is a bit older in the screenshot because I also tried uninstalling the latest graphviz and then installing this version because people seemed to have got it working in this version.
Approach 2) I have installed graphviz via the msi from their website, and also through pip install graphviz. Also done installing graphviz first and then pydot (If the order even mattered as some solutions suggested). Even tried doing it with pydotplus.
Approach 3) Solutions seemed to hint at tinkering with pydot.find_graphviz
in the pydot.py. However this function is not present in pydot versions above 1.1.0 (2016). And i think the latest versions of python do not support the installation of this pydot version.
Approach 4) I ran command prompt as admin and then did dot -c
and dot -v
as one solution suggested. Honestly, I don't even know what this did. Some promising stuff but still didn't fix it.
I'd greatly appreciate some insights on this. Thank you!