propapating exceptions
Andreas Jung
ajung at sz-sb.de
Sat Jul 17 11:26:28 EDT 1999
More information about the Python-list mailing list
Sat Jul 17 11:26:28 EDT 1999
- Previous message (by thread): propapating exceptions
- Next message (by thread): canvas, postscript, and fontmap
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Fri, Jul 16, 1999 at 08:43:33PM -0500, Thomas Bryan wrote: > > I can't find the reference now, but I think that I read in > the Python docs that calling raise without an argument inside > an except, reraises the error. > > That is, > > try: > some sql command > except ODBC.MySQL.OperationalError, msg: > if msg[1] == CR_SERVER_GONE_ERROR: # (snarfed out of errmsg.h) > restart server, try again > else: > raise > > Does that work? This should work - raise without any arguments should reraise the same exception without modifying the traceback - that's at least the way it works on my system. Cheers, Andreas
- Previous message (by thread): propapating exceptions
- Next message (by thread): canvas, postscript, and fontmap
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list