[MERGE] Tree._iter_changes

Aaron Bentley aaron.bentley at utoronto.ca
Sat Dec 2 02:45:11 GMT 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

John Arbash Meinel wrote:
>> This bundle implements the Tree._iter_changes API, which is intended to
>> unify our various change-detection routines.
>>
> 
> I'm replying here because BB seems unhappy with me. But +1 conditional.

It seems okay, but kinda slow, to me.  If problems persist, please let
me know in more detail.

> Sorry I didn't get to this yesterday.

Thanks for doing it.  I'm not fussed about the particular timing.  It's
certainly not your job to review everything.

> I'm not positive that making the interface private is sufficient,
> considering it is being actively used by parts of the code. But I'm
> willing to pretend it is, so that we can move forward.

Well, it should mean we don't have to worry about non-bzrlib clients, I
hope.  But getting it into mainline should mean that Robert will soon
merge it and be able to give us feedback.

> v- To be consistent, the parameter should probably be named 'stat_value'.
> I realize it involves changing a little more code, but it is better to
> have a nicer api.

Will do.

> -    def _fingerprint(self, abspath):

> Why did you chose to iterate over to and then from, rather than
> iterating over both simultaneously (as I did in _compare_trees())?

1. I wanted to provide the results in to_tree order, parents before
children.
2. It made the code much more understandable.

> One thing I'd really like to see as I move forward with splitting up
> inventory, or at least adding a recursive 'last_changed' indicator, is
> that we don't have to iterate over the complete inventories in the
> common case.

This implementation is the most general implementation.  But since it
uses the inter-trees mechanism, we can implement new versions if they're
more efficient for particular tree-types.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFcOi30F+nu1YWqI0RAlp0AJ9eyYH+vgojJM3rNhPVbLqNkQj14wCfTYM8
ziUmPuC7O4xRzhGDWtg6Oig=
=wVcB
-----END PGP SIGNATURE-----




More information about the bazaar mailing list