[MERGE] setlocale (#128496)
Martin von Gagern
Martin.vGagern at gmx.net
Sat Jun 21 17:49:29 BST 2008
Hi!
Martin Pool wrote:
> My original mail was a bit truncated: it's true that we shouldn't be
> catching all these errors, but a more important point is that we
> generally don't want to catch errors "just in case". The exceptions
> are well defined layers where that's clearly part of their job eg to
> print the error to the user or to cancel an operation. We've
> generally found if you do this it tends to hide bugs from testing and
> also from the developer.
>
> So what I really meant to ask was, why was that code like it is.
As my merge request seems to have stalled, I now wrote a version that
won't try to catch any exceptions. Currently that works for me.
Trying to reproduce the scenario that lead me to introduce all that
try/catch in the first place, I encountered the following lines:
ValueError: <unprintable ValueError object>
I am not really sure, but it might just be that I had seen those,
assumed a problem with my string handling code, and expanded it to
include even more cases. Closer investigation now showed that this line
was generated by traceback and was probably handed to the report modules
in just this way.
If that was in fact the reason for me adding the elaborate exception
handling, then that work was in vain, as no amount of string formatting
is likely to change the printed backtrace.
I hope that this adjusted version of the patch can now be merged without
further delay.
Greetings,
Martin
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: setlocale-3496.patch
Url: https://lists.ubuntu.com/archives/bazaar/attachments/20080621/44955003/attachment-0001.diff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20080621/44955003/attachment-0001.pgp
More information about the bazaar
mailing list