Changeset 5516
- Timestamp:
- 10/30/09 09:16:22 (3 weeks ago)
- Location:
- trunk/bcfg2
- Files:
-
- 2 modified
-
debian/changelog (modified) (1 diff)
-
src/sbin/bcfg2-info (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/bcfg2/debian/changelog
r5512 r5516 2 2 3 3 * Update packaging 4 * Switch to plain debhelper5 * Switch from pycentral to python-support6 * Move homepage to the dedicated Homepage field7 * Update Standards-Version to 3.8.3.04 * Switch to plain debhelper 5 * Switch from pycentral to python-support 6 * Move homepage to the dedicated Homepage field 7 * Update Standards-Version to 3.8.3.0 8 8 9 9 -- Sami Haahtinen <ressu@debian.org> Sat, 24 Oct 2009 00:20:51 +0300 -
trunk/bcfg2/src/sbin/bcfg2-info
r5504 r5516 10 10 import lxml.etree 11 11 import os 12 import profile13 import pstats14 12 import sys 15 13 import tempfile 14 15 try: 16 import profile 17 import pstats 18 have_profile = True 19 except: 20 have_profile = False 16 21 17 22 import Bcfg2.Logger … … 411 416 412 417 def do_profile(self, arg): 418 if not have_profile: 419 print("Profiling functionality not available") 420 return 413 421 tracefname = tempfile.mktemp() 414 422 p = profile.Profile() … … 437 445 setup = Bcfg2.Options.OptionParser(optinfo) 438 446 setup.parse(sys.argv[1:]) 439 print(setup) 440 if setup['profile']: 447 if setup['profile'] and have_profile: 441 448 prof = profile.Profile() 442 449 loop = prof.runcall(infoCore, setup['repo'], setup['plugins'], … … 445 452 displayTrace(prof) 446 453 else: 454 if setup['profile']: 455 print("Profiling functionality not available") 447 456 loop = infoCore(setup['repo'], setup['plugins'], setup['password'], 448 457 setup['encoding'], setup['event debug'])