Info search

Wojtek Walczak gminick at hacker.pl
Sat Dec 7 15:42:57 EST 2002


Dnia Sat, 07 Dec 2002 13:40:12 GMT, PigioŽ napisał(a):
> When can I found details about URLErrror exception within urllib2 library?
Here's a piece of code from Python-2.2.2/Lib/urllib2.py(line 148 to 155):

class URLError(IOError):
    # URLError is a sub-type of IOError, but it doesn't share any of
    # the implementation.  need to override __init__ and __str__
    def __init__(self, reason):
        self.reason = reason

    def __str__(self):
        return '<urlopen error %s>' % self.reason

;]

-- 
[ ] gminick (at) underground.org.pl  http://gminick.linuxsecurity.pl/ [ ]
[ "Po prostu lubie poranna samotnosc, bo wtedy kawa smakuje najlepiej." ]



More information about the Python-list mailing list