[RFC] Joining of annotated and plain knits

Ian Clatworthy ian.clatworthy at internode.on.net
Mon Sep 24 14:34:01 BST 2007


Last week Robert put out a a list of things that needed to be addressed
before packs could be supported in bzr.dev. Joining together knits where
one was annotated and the other was not was near the top of that list.

As I had never looked at knit.py before, it sounded like a perfect
learning opportunity and it was/is. :-) The attached patch is close I
believe.

I'd like some input/assistance from the knit gurus please to complete
this. I've taken the one test_knit_join test method and replaced it with
4 methods, one for each source-target combination. As best I can tell,
it's working perfectly except for the plain->annotated case after a
merge. However, it's not obvious to me whether I'm doing something wrong
or if the bug is elsewhere in our code, e.g. in the merge code or
annotate code.

If someone would like to assist, there's a print statement commented out
around line 2243 of knit.py. To see how the conversion works, uncomment
that and run

  bzr selftest test_knit_join_plain_to_anno

or

  bzr selftest test_knit_join_anno_to_plain

Thanks,
Ian C.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: knit-anno-plain-join.patch
Type: text/x-patch
Size: 10563 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20070924/e4f68ecc/attachment.bin 


More information about the bazaar mailing list