diff options
Diffstat (limited to 'examples/python2.7/patches/hotshot-import.diff')
-rw-r--r-- | examples/python2.7/patches/hotshot-import.diff | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/examples/python2.7/patches/hotshot-import.diff b/examples/python2.7/patches/hotshot-import.diff new file mode 100644 index 0000000..80d6407 --- /dev/null +++ b/examples/python2.7/patches/hotshot-import.diff @@ -0,0 +1,17 @@ +# DP: hotshot: Check for the availability of the profile and pstats modules. + +--- a/Lib/hotshot/stats.py ++++ b/Lib/hotshot/stats.py +@@ -1,7 +1,10 @@ + """Statistics analyzer for HotShot.""" + +-import profile +-import pstats ++try: ++ import profile ++ import pstats ++except ImportError, e: ++ raise ImportError, str(e) + '; please install the python-profiler package' + + import hotshot.log + |