Rev 4090: (robertc) Add clarifying comments to check.py. (Robert Collins) in file:///home/pqm/archives/thelove/bzr/%2Btrunk/

Canonical.com Patch Queue Manager pqm at pqm.ubuntu.com
Sun Mar 8 22:23:21 GMT 2009


At file:///home/pqm/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 4090
revision-id: pqm at pqm.ubuntu.com-20090308222317-d1nw017gzfen1aqs
parent: pqm at pqm.ubuntu.com-20090308213256-h1hh8zwruuprz26c
parent: robertc at robertcollins.net-20090308055450-3px3atlqj1iagueu
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Sun 2009-03-08 22:23:17 +0000
message:
  (robertc) Add clarifying comments to check.py. (Robert Collins)
modified:
  bzrlib/check.py                check.py-20050309040759-f3a679400c06bcc1
    ------------------------------------------------------------
    revno: 4084.4.1
    revision-id: robertc at robertcollins.net-20090308055450-3px3atlqj1iagueu
    parent: pqm at pqm.ubuntu.com-20090306030219-enauehb3achqqq7c
    committer: Robert Collins <robertc at robertcollins.net>
    branch nick: check-comments
    timestamp: Sun 2009-03-08 16:54:50 +1100
    message:
      Minor comments clarifying check.py.
    modified:
      bzrlib/check.py                check.py-20050309040759-f3a679400c06bcc1
=== modified file 'bzrlib/check.py'
--- a/bzrlib/check.py	2009-01-17 01:30:58 +0000
+++ b/bzrlib/check.py	2009-03-08 05:54:50 +0000
@@ -173,6 +173,7 @@
 
         for parent in rev.parent_ids:
             if not parent in self.planned_revisions:
+                # rev has a parent we didn't know about.
                 missing_links = self.missing_parent_links.get(parent, [])
                 missing_links.append(rev_id)
                 self.missing_parent_links[parent] = missing_links
@@ -188,6 +189,11 @@
                     self.ghosts.append(rev_id)
 
         if rev.inventory_sha1:
+            # Loopback - this is currently circular logic as the
+            # knit get_inventory_sha1 call returns rev.inventory_sha1.
+            # Repository.py's get_inventory_sha1 should instead return
+            # inventories.get_record_stream([(revid,)]).next().sha1 or
+            # similar.
             inv_sha1 = self.repository.get_inventory_sha1(rev_id)
             if inv_sha1 != rev.inventory_sha1:
                 raise BzrCheckError('Inventory sha1 hash doesn\'t match'




More information about the bazaar-commits mailing list