If pstat file generated by hotspot profiler epydoc will fail with error "Bad marshall data"
Error caused by explicit openning by psats.Stats( ... )
epydoc.cli, line 771:
profile_stats = pstats.Stats(options.pstat_files)
Documentation pstats documentation provides information:
"""The file selected by the above constructor must have been created by the corresponding version of profile or cProfile. To be specific, there is no file compatibility guaranteed with future versions of this profiler, and there is no compatibility with files produced by other profilers.
So, it's not an unexpected behaviour.
I am using a patch, which tries to re-open file using hotshot.stats.load function if pstats.Stats fails, but I didn't attach it because I didn't dig deeply in a problem and I am not sure that it is a correct approach. For example, it might be better idea to define explicitly pstat's version.
Log in to post a comment.