[issue3429] urllib.urlopen() return type

ThomasH report at bugs.python.org
Fri Aug 8 09:18:21 CEST 2008


ThomasH <thomas.bugzilla at gmx.net> added the comment:

On Fri, Aug 8, 2008 at 2:04 AM, Senthil <report at bugs.python.org> wrote:
>
> Senthil <orsenthil at gmail.com> added the comment:
>
> I agree with Benjamin on this issue, describing what is a "File like Object" is
> so much un-needed in Python and especially at urlopen function. Users have been
> able to understand and use it properly from a long time.

If only it were more file-like. But, oh, it adds info() and geturl()
methods which you have to string-search for to find the proper
description in the prose. And, ah, the size argument of the read()
method doesn't quite behave like on other file-like objects, but there
you go. And, uh, by the way, you really can't use it in places "where
a true built-in file object is required" (and I'm sure everybody knows
what that means). - So much for file-like.

I have no doubt that people can get along with the description as it
is, because that's what they always try. My main point was that it is
"less approachable and breaks the usual format of a class
documentation". But I see there is much agreement in keeping the
status quo.

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


More information about the Python-bugs-list mailing list