At 08:21 PM 9/30/04 +1000, Nick Coghlan wrote: >However, another possibility occurred to me: > >try: > # Do stuff >except sys.special_exceptions: > raise >except: > # Deal with all the mundane stuff > >With an appropriately defined tuple, that makes it easy for people to "do the >right thing" with regards to critical exceptions. Such a tuple could also be >useful for invoking isinstance() and issubclass(). +1. This would be a big help for developers, if only in that it will tell us what exceptions we ought to do this with. IMO, this is probably important enough to make it a builtin; maybe call it CriticalExceptions or some such. Also, maybe in 2.5 we could begin warning about bare excepts that aren't preceded by non-bare exceptions.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4