[Python-ideas] requests in the stdlib?

Nick Coghlan ncoghlan at gmail.com
Mon Nov 4 23:52:55 CET 2013


On 5 Nov 2013 06:15, "Barry Warsaw" <barry at python.org> wrote:
>
> On Nov 04, 2013, at 03:51 PM, Matěj Cepl wrote:
>
> >I guess I am not the first one who experienced a profound life-changing
> >epiphany of meeting with the requests package.  Yesterday after fighting
for
> >hours with urllib2 (and GitHub API) and failing, I have succeeded with
> >requests in five minutes.
> >
> >Despite how much I dislike using libraries outside of the stdlib (yes,
> >unittest is the way to go, please, no nosetests and py.test for me), I
am now
> >persuaded that requests API is the best thing since ... I don't know,
API of
> >feedparser (RIP, Aaron Swartz)?
> >
> >So, I guess, somebody had to already suggest pulling requests into
> >stdlib. Could somebody here point me to the resulting discussion, please?
>
> requests is nice, and I like the API as well.  I wouldn't be opposed to
> pulling it into the 3.4 stdlib if upstream were amenable.
>
> However, the specific implementation would have to stop vendoring various
> packages such as chardet and urllib3, and it would have to make it easy
to use
> system provided certificates instead of bundling its own (there's been
> discussion on this issue for Python as well).
>
> We have to carry deltas in Debian to prevent this vendorization, and I
think
> for Python stdlib they would be unacceptable.  That probably means at
least
> also pulling in urllib3 and chardet.

PEP 453 vendors the whole thing as part of pip :) (but that's just one of
the many ways that PEP makes life interesting for Linux distros).

Anyway, yes, the requests *API* does likely represent the future standard
HTTP(S) interface for Python, but more likely through an alternative
asyncio compatible implementation rather than the current synchronous-only
implementation. For now "pip install requests" (or the platform specific
equivalent) is the way to go.

Reference:
http://python-notes.curiousefficiency.org/en/latest/conferences/pyconus2013/20130313-language-summit.html#requests

Cheers,
Nick.

>
> -Barry
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20131105/53ba4bb6/attachment.html>


More information about the Python-ideas mailing list