[Tutor] Exception attributes?

David Rock david at graniteweb.com
Sat Jul 10 06:45:28 CEST 2004


* Jerry McBride <mcbrides9 at comcast.net> [2004-07-09 19:52]:
> 
> I'm a new Python hacker and I could use a little help.
> 
> 
> I'm in the process of figuring out try: clauses and I've run into a hitch.
> 
> It seems that each exception has different attributes. How can I discover
> what attributes are?

sys.exc_info() will give you information about the exception that was
just raised.

-- 
David Rock
david at graniteweb.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://mail.python.org/pipermail/tutor/attachments/20040709/046ad66a/attachment.pgp


More information about the Tutor mailing list