On 09/23/2013 02:35 PM, Antoine Pitrou wrote:
On Tue, 24 Sep 2013 07:19:14 +1000 Nick Coghlan
wrote: On 24 Sep 2013 01:24, "Antoine Pitrou"
wrote: On Mon, 23 Sep 2013 18:51:04 +1000 Nick Coghlan
wrote: On 23 September 2013 18:45, Antoine Pitrou
wrote: Le Mon, 23 Sep 2013 18:17:51 +1000, Nick Coghlan
a écrit : Here's what I suggest changing that error to:
>>> del x Unraisable exception suppressed when calling
> Traceback (most recent call last): File "<stdin>", line 3, in __del__ RuntimeError: Going away now Why not simply "Exception automatically caught in <bound method C.__del__> [...]" ?
It only answers the "what" (i.e. the exception was automatically caught), without addressing the "why" (i.e. because there wasn't anything else useful the interpreter could do with it)
Yes, but I agree with Greg that "unraisable" is wrong. After all, it was raised, and it can even be caught by the programmer (inside __del__).
The word doesn't literally mean the exception itself was unraisable. It means it was raised, we caught it and we're writing it to stderr because we *can't raise it again*.
But that's because you already know what it's supposed to convey. The average user doesn't, and only sees "unraisable".
All the more reason to have text in the error message that is easily searchable. -- ~Ethan~