[Python-Dev] Symbolic errno values in error messages

Yannick Gingras ygingras at ygingras.net
Fri May 16 16:52:34 CEST 2008


"Alexander Belopolsky" <alexander.belopolsky at gmail.com> writes:

>>>> try:
> ...    open('/')
> ... except Exception,e:
> ...    pass
> ...
>>>> print e
> [Errno 21] Is a directory
>
> So now I am not sure what OP is proposing.  Do you want to replace 21
> with EISDIR in the above?

Yes, that's what I had in mind.

-- 
Yannick Gingras


More information about the Python-Dev mailing list