[PATCH] Convert bundle errors from Exception to BzrNewError

Aaron Bentley aaron.bentley at utoronto.ca
Sat Aug 5 23:03:03 BST 2006


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

Hermann Kraus wrote:
> Hi,
> 
> all bundle errors were just Exceptions instead of BzrErrors or
> BzrNewErrors.
> I had to change one place where no error message was given to
> MalformedHeader.

Thanks for your patch.  I created those errors that way because they're
intended to be caught, not seen by the user, but perhaps that's naive.
There's certainly no harm in making them consistent.

There are a few style issues:
The line you changed to give a message to MalformedHeader is more than
79 character wide.  It should be split and/or rewritten.

The spacing between classes in errors.py is not consistent.  There
should always be two blank lines between classes, and none after
MalformedFooter, because it's the last class in the file.

Also, please don't don't use the file extension ".bundle" when attaching
bundles.  This causes your mail client to treat it as a binary file,
which makes it awkward for us to read, and means that the source code
doesn't appear in replies.  I suggest ".patch" or ".diff".

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

iD8DBQFE1RWX0F+nu1YWqI0RAtYNAJ4wSjTaWQPTh7tkkq9i2AyiuUw/1gCeOBln
lysYkRd7vH+dLGblm05intI=
=jTSg
-----END PGP SIGNATURE-----




More information about the bazaar mailing list