[merge] remove uses of 'assert False' to raise an exception
Robert Collins
robertc at robertcollins.net
Wed Jun 27 05:40:35 BST 2007
On Wed, 2007-06-27 at 14:37 +1000, Martin Pool wrote:
> There were some places in bzrlib where we said
>
> assert False, "something bad happened"
>
> This is bad because assertions aren't run under python -O, and so the
> interpreter would run on regardless of what was meant to be a fatal
> problem. Also in most cases there was a more useful exception we can
> raise instead.
>
> python -O is not very interesting or commonly used at the moment, but
> I had a note to clean them up.
+1
-Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20070627/c54d84f7/attachment.pgp
More information about the bazaar
mailing list