Why Error is derived from EnvironmentError in shutil.py?
Steven D'Aprano
steven at REMOVE.THIS.cybersource.com.au
Wed Nov 11 23:55:50 EST 2009
On Wed, 11 Nov 2009 22:46:34 -0600, Peng Yu wrote:
> I see Error is derived from EnvironmentError in shutil.py.
>
> class Error(EnvironmentError):
> pass
>
> I'm wondering why EnvironmentError can not be raised directly. Why Error
> is raised instead?
Probably to do with the personal taste of the author.
http://docs.python.org/library/shutil.html#shutil.Error
--
Steven
More information about the Python-list
mailing list