diff options
author | Emile Anclin <emile.anclin@logilab.fr> | 2010-11-08 13:24:56 +0100 |
---|---|---|
committer | Emile Anclin <emile.anclin@logilab.fr> | 2010-11-08 13:24:56 +0100 |
commit | db2d049d8593ca7d710744b5f697f1c2847b7148 (patch) | |
tree | 88468afba730d9eadba043494f5f2381d99d0042 /lint.py | |
parent | b30b9e2de798cf5d2c9863dae8824a42cfcd80d2 (diff) | |
download | pylint-db2d049d8593ca7d710744b5f697f1c2847b7148.tar.gz |
py3k: update profile option
Diffstat (limited to 'lint.py')
-rw-r--r-- | lint.py | 8 |
1 files changed, 3 insertions, 5 deletions
@@ -851,11 +851,9 @@ been issued by analysing pylint output status code sys.path.insert(0, os.getcwd()) if self.linter.config.profile: print >> sys.stderr, '** profiled run' - from hotshot import Profile, stats - prof = Profile('stones.prof') - prof.runcall(linter.check, args) - prof.close() - data = stats.load('stones.prof') + import cProfile, pstats + cProfile.runctx('linter.check(%r)' % args, globals(), locals(), 'stones.prof' ) + data = pstats.Stats('stones.prof') data.strip_dirs() data.sort_stats('time', 'calls') data.print_stats(30) |