pycallgraph2
pycallgraph2 copied to clipboard
GraphViz output file name truncated if it contains space
If the output file name provided to GraphViz contains space character, only the part up to the space ends up as the file name. Workaround involves taking file name into quotes. This is also a potential security vunerability.
profiler = PyCallGraph(output=GraphvizOutput(output_file="name with spaces.png"))
profiler.start()
...
profiler.done()
Workaround:
profiler = PyCallGraph(output=GraphvizOutput(output_file="\"name with spaces.png\""))