I am trying to run PyCallgraph module on my application. My application runs on Mac and I am running the application from PyCharm Here is what I have tried
def main(url):
from pycallgraph import PyCallGraph
from pycallgraph.output import GephiOutput, GraphvizOutput
graphviz = GraphvizOutput()
with PyCallGraph(output=graphviz):
obj = MyApp("agr1")
obj.extract('372','100001' , '999')
I am getting the following error ...
libpath/shortest.c:324: triangulation failed
libpath/shortest.c:192: source point not in any triangle
Error: in routesplines, Pshortestpath failed
Traceback (most recent call last):
File "/Users/anurag/Work/quad-projects/quad-hge/src/main/python/extractor/hgextractor.py", line 63, in <module>
main(url)
File "/Users/anurag/Work/quad-projects/quad-hge/src/main/python/extractor/hgextractor.py", line 51, in main
hge.extract('372','100001' , '999', url_list)
File "/Users/anurag/.virtualenvs/robot/lib/python2.7/site-packages/pycallgraph/pycallgraph.py", line 38, in __exit__
self.done()
File "/Users/anurag/.virtualenvs/robot/lib/python2.7/site-packages/pycallgraph/pycallgraph.py", line 81, in done
self.stop()
File "/Users/anurag/.virtualenvs/robot/lib/python2.7/site-packages/pycallgraph/pycallgraph.py", line 90, in generate
output.done()
File "/Users/anurag/.virtualenvs/robot/lib/python2.7/site-packages/pycallgraph/output/graphviz.py", line 112, in done
'code %(ret)i.' % locals())
pycallgraph.exceptions.PyCallGraphException: The command "dot -Tpng -opycallgraph.png /var/folders/00/z1t7sw2x1ml1ydhgp084c1xh0000gn/T/tmphl_rNH" failed with error code 11.
Process finished with exit code 1
I even tried installing graphviz
on my Mac using brew install graphviz
and setting $PATH variable on my PyCharm editor as described here pycallgraph with pycharm does not work
I don't know the exact root cause for this and I am stuck at this for last 2-3 days.