Amount of data transferred for 'no-op' pull

Martin Pool mbp at canonical.com
Wed Dec 9 23:24:26 GMT 2009


2009/12/10 John Arbash Meinel <john at arbash-meinel.com>:

> I dug further, and it seems that doing 'branch.pull(other_branch)'
> actually does end up calling fetch, and checking the remote revision
> graph even though the branch.last_revision() on both sides are
> identical. Adding a check for:
>
> if branch.last_revision() != remote_branch.last_revision():
>  branch.pull(remote_branch, overwrite=True)
>
> dropped the transfer down to 51kB, which is more expected.
>
> I thought Branch.pull(other) already had the last_revision shortcut. Did
> something happen to it?

I don't recall what happened in the past, but you should put up a
patch for this.  (I don't understand why you have overwrite=True in
your example, but it's the actual proposed patch that matters.)

-- 
Martin <http://launchpad.net/~mbp/>



More information about the bazaar mailing list