Raising a specific OSError

David Hirschfield davidh at ilm.com
Fri Apr 21 18:21:21 EDT 2006


I know this should be obvious, but how does one raise a specific type of 
OSError?
When I attempt to perform a file operation on a non-existent file, I get 
an OSError: [Errno 2], but what if I want to raise one of those myself?

Thanks in advance,
-Dave

-- 
Presenting:
mediocre nebula.




More information about the Python-list mailing list