[Python-3000] Some problems with urllib

Nick Coghlan ncoghlan at gmail.com
Tue Jun 24 14:22:54 CEST 2008


The last of the PEP 3108 (standard lib reorg) changes landed for the 
first beta, so urllib is now a package of assorted URL related modules.

 >>> import urllib
 >>> help(urllib)
Help on package urllib:

NAME
     urllib

FILE
     /home/ncoghlan/devel/py3k/Lib/urllib/__init__.py

PACKAGE CONTENTS
     error
     parse
     request
     response
     robotparser

DATA
     __package__ = None


 >>> import urllib.request
 >>> opener = urllib.request.FancyURLopener({})

(Hmm pydoc shouldn't be displaying __package__ as a DATA entry, since 
PEP 361 means that all modules now have it by default... issue 3190 
created for that)

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia
---------------------------------------------------------------
             http://www.boredomandlaziness.org


More information about the Python-3000 mailing list