Rev 82: Clean up some of the post-hook formatting, etc. in http://bzr.arbash-meinel.com/plugins/history_db

John Arbash Meinel john at arbash-meinel.com
Mon Apr 12 20:36:04 BST 2010


At http://bzr.arbash-meinel.com/plugins/history_db

------------------------------------------------------------
revno: 82
revision-id: john at arbash-meinel.com-20100412193557-pyrg3hst8cl5wz1k
parent: john at arbash-meinel.com-20100412193508-gr6rco2tmgzs2ef5
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: history_db
timestamp: Mon 2010-04-12 14:35:57 -0500
message:
  Clean up some of the post-hook formatting, etc.
-------------- next part --------------
=== modified file '__init__.py'
--- a/__init__.py	2010-04-12 19:35:08 +0000
+++ b/__init__.py	2010-04-12 19:35:57 +0000
@@ -391,8 +391,8 @@
 
 def _history_db_post_change_branch_tip_hook(params):
     """Run when the tip of a branch changes revision_id."""
+    t0 = time.clock()
     import pprint
-    t0 = time.clock()
     history_db_path = _get_history_db_path(params.branch)
     if history_db_path is None:
         trace.mutter('Note updating history-db, "history_db_path"'
@@ -405,9 +405,10 @@
     t2 = time.clock()
     importer.build_mainline_cache()
     t3 = time.clock()
-    trace.note('History DB took %.3fs, %.3fs to init, %.3fs to import'
+    trace.note('history_db post-change-hook took %.3fs'
+               ' (%.3fs to init, %.3fs to import)'
                % (t3-t0, t1-t0, t2-t1))
-    trace.note('Stats:\n%s' % (pprint.pformat(dict(importer._stats)),))
+    trace.mutter('Stats:\n%s' % (pprint.pformat(dict(importer._stats)),))
 
 
 



More information about the bazaar-commits mailing list