In <[EMAIL PROTECTED]>, HMS Surprise
wrote:

> The snippet below causes an attribute error.
> 
> AttributeError: module 'urllib' has no attribute 'urlopen'
> 
> I am using python 2.2.3. According to the documentation at C:
> \Python22\Doc\lib urllib has a function called urlopen.

Do you have a file called `urllib.py` in the current directory?  Then this
gets imported instead of the module in the standard library.

Add this directly after the ``import`` to see what's happening:

print urllib.__file__
print dir(urllib)

Ciao,
        Marc 'BlackJack' Rintsch
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to