[issue10050] urllib.request still has old 2.x urllib primitives

Senthil Kumaran report at bugs.python.org
Sun Mar 20 13:51:40 CET 2011


Senthil Kumaran <orsenthil at gmail.com> added the comment:

Antoine Pitrou wrote:
> Can you clarify the issue?

URLopener which is an old class from the merge of urllib and urllib2
and it can be slowly and safely removed. If we go this line, then I
assume it has to have a DeprecationWarning before we remove it. Should
we or not?

My thought is, in Python 3.x these may not be in use, but still if we
remove without DeprecationWarning, it could raise concerns with some
folks (given some discussion about this recently when people trying to
upgrade from 2.x to 3.x).

At the moment, urlretrieve function is calling  URLopener.retrieve internally.
But this patch addresses urlretrive function at much higher level and leaves
the URLopener.retrieve in a hanging state. So, I was thinking how to
handle this scenario.

Change URLopener.retrieve also with the cleaner and modern code, but
and add a DeprecationWarning in those.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue10050>
_______________________________________


More information about the Python-bugs-list mailing list