[PACKS] FORMAT CHANGE IMPENDING

Robert Collins robertc at robertcollins.net
Tue Aug 28 00:19:48 BST 2007


On Tue, 2007-08-28 at 08:54 +1000, Robert Collins wrote:
> On Mon, 2007-08-27 at 09:51 -0400, Aaron Bentley wrote:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> > 
> > Robert Collins wrote:
> > 
> > > Ok, this was trying to build the working tree but failed; I'll test this
> > > exact sequence myself and track it down asap tomorrow.
> > 
> > I mailed a traceback like this to you on Friday.  Did you get it?
> 
> I have confirmed this; it seems to be missing data:
> (Pdb) self
> GraphKnitRepository1('file:///home/robertc/packs.packs/.bzr/')
> (Pdb) file_id
> 'rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6'
> (Pdb) revision_id
> 'mbp at sourcefrog.net-20051122043014-6df209fd93033b59'
> (Pdb) 
> 
> (I ran with BZR_PDB=1, upped to the iter_file_bytes call).

So, robertc at robertcollins.net-20050919044328-0205c679f3051340 is the
listed left most parent of that text, and the error is occuring because
the parent is not available. The revision is in the revision index, but
the text isn't because:
>>> import bzrlib.repository
>>> r = bzrlib.repository.Repository.open('.')
>>> i =
r.get_inventory('robertc at robertcollins.net-20050919044328-0205c679f3051340')
>>> i[''rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6'
  File "<stdin>", line 1
    i[''rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6'
                   ^
SyntaxError: invalid syntax
>>> i['rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6']
InventoryFile('rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6',
'.rsyncexclude', parent_id='TREE_ROOT',
sha1='9b554377cb71ac16314f0869603dba0d41a180c0', len=152)
>>> i['rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6'].revision
'mbp at sourcefrog.net-20050505063818-3eb3260343878325'
>>> 

The inventory claims that my commit did not alter it; yet the knit sees
a new revision.
>>>
r.get_revision('robertc at robertcollins.net-20050919044328-0205c679f3051340').parent_ids
['robertc at robertcollins.net-20050916132832-7de2e991a3d0288f',
'john at arbash-meinel.com-20050918181642-929509099f2cf7e8']

Two parents:
>>> i2 =
r.get_inventory('robertc at robertcollins.net-20050916132832-7de2e991a3d0288f')
>>> i3 =
r.get_inventory( 'john at arbash-meinel.com-20050918181642-929509099f2cf7e8')

>>> i2['rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6'].revision
'mbp at sourcefrog.net-20050505063818-3eb3260343878325'
>>> i3['rsyncexclude-20050408053852-27e0a5928b6829f645beb2e6'].revision
'mbp at sourcefrog.net-20050505063818-3eb3260343878325'

So both parents have the same last modified - clearly the knit record
here is basically batshit insane. 

This is what Aaron's reconcile work address's (to the extent of ensuring
that what will be pulled will be sufficiently complete to be able to
construct the texts again). (There are other forms of whackiness that
can occur such as the inventory itself having the wrong last-modified
pointer, but these, while we should verify them, do not cause 'bzr
branch' to fail).

In short, this isn't a bug in packs so much as the expected consequence
of the data corruption Aaron's patch fixes.

I've added to my TODO list an item to write the pack version of the same
as soon as that patch makes its way through the process to pqm. Till
then, folk dogfooding should stay with pack.knits, which I'll keep fully
up to date.

-Rob
-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20070828/1fca168b/attachment.pgp 


More information about the bazaar mailing list