[patch] fix bug 48136 bzr status, diff, etc do not work properly after remote push

Aaron Bentley aaron.bentley at utoronto.ca
Fri Oct 27 16:23:55 BST 2006


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

John Arbash Meinel wrote:
> Cheuksan Edward Wang wrote:
> 
>>Thanks a lot. I have added the tests to test_status.py and test_diff.py .
>>
>>
>>On 10/22/06, *Aaron Bentley* < aaron.bentley at utoronto.ca
>><mailto:aaron.bentley at utoronto.ca>> wrote:
>>
>>Cheuksan Edward Wang wrote:
>>
>>
>>>I have fixed 48136. I cannot write a simple blackbox test because a
>>>local push always updates the working tree. Can someone teach me
>>
>>how to
>>
>>>write a test for this?
>>
>>You're not really testing push, but diff and status.  So you can just
>>use WorkingTree.set_last_revision() to force the tree to be out of date.
>>
>>Aaron
> 
> 
> Sorry this took so long to review, +1 from me. Aaron, can you give a
> second +1?
> 
> Also, I wonder if this is only part of the fix. Because we want heavy
> checkouts to act like lightweight ones, we probably should also be
> checking if tree.last_revision() matches (pseudocode)
> tree.branch.master().last_revision(). But I'll let that be a follow up
> patch. For one thing, it adds a potential network connection to
> something that could otherwise be really fast. (bzr status in a heavy
> checkout).

Yes, that's been the problem I've had when considering this before.

I'm not sure we really want this in diff.  Diff can potentially use
all-local data, even when the branch is remote.

Using heavyweight checkouts instead of lightweight ones with remote
branches is just a convention.  So doing this does require a connection
to the branch, which is a new requirement.

Doing it in status seems more sensible, but I don't know whether it
should be a warning.  Wouldn't it make sense to include it as part of
the normal status output?

So I'm at +0.5 here.  I don't want diff doing this.  I don't require
changing the way it appears in status, but it's at least worth considering.

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

iD8DBQFFQiSL0F+nu1YWqI0RAljRAJ9nffkCNlPUvsKVUqMuSaruU3Kr0QCcCbGC
B+jf7QPiybW7Qe5pffaHuaM=
=Zh/H
-----END PGP SIGNATURE-----




More information about the bazaar mailing list