[bug] bzr commit with nothing changed fails with the wrong exception

John Arbash Meinel john at arbash-meinel.com
Fri Jun 23 17:28:49 BST 2006


After Martin's cleanups, it seems bzr commit fails with the wrong error
when you try to commit an 'unchanged' tree.

Basically, it tries to raise a BzrCommandError, but uses the wrong
parameters, so a TypeError gets raised.
The blackbox tests didn't catch that, because they only test that there
is an exception, not what the exception is.

To reproduce this, just get the latest bzr.dev and do:

./bzr commit -m foo foo

Now the real fix for the above command is that we should say '"foo" is
not versioned' like we started doing for diff and status.
But this fix needs to happen, too.

I'm not sure if trapping the output of run_bzr is the best thing, but we
should start writing some interface tests that measure what the user is
actually seeing, so that we know our errors are being helpful.

John
=:->
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: empty-commit-exception.patch
Url: https://lists.ubuntu.com/archives/bazaar/attachments/20060623/5380a1e9/attachment.diff 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060623/5380a1e9/attachment.pgp 


More information about the bazaar mailing list