On 2010-09-08, Steven D'Aprano <st...@remove-this-cybersource.com.au> wrote: > On Wed, 08 Sep 2010 14:44:12 +0000, Grant Edwards wrote: >> >>> If you don't trap them just right, they cause a stack trace, >> >> Not always. That is the effect of not trapping them at all. However, >> you can trap them incorrectly -- which can result in hard-to-track down >> problems. >> >> The main example of this is a "bare except" clause that not only catches >> and handles the "expected" exception but also catches (and >> mishandles/ignores) an unexpected one. > > Ah, fair enough. That would be a false positive error -- catching too > much rather than too little. > > Still, that's no better, or worse, than misinterpreting special error > codes that are returned by functions.
No, I didn't mean to imply that was the case. I agree with your conclusion. I find it much easier to screw things up using the "exceptional return value" method than the "exception raise" method. -- Grant Edwards grant.b.edwards Yow! Psychoanalysis?? at I thought this was a nude gmail.com rap session!!! -- http://mail.python.org/mailman/listinfo/python-list