Skip to main content

Experimental lower-level async HTTP client for Requests 3.0


Goals: take urllib3 codebase, add async support (with multiple backends), default to trio execution of async functions for blocking calls.

Usage

Async usage:

import requests_core

url = "http://httpbin.org/uuid"

async def main():
    r = await requests_core.request('GET', url)
    print(r.headers)
    print(await r.read())
>>> import trio
>>> trio.run(main)
    HTTPHeaderDict({'connection': 'keep-alive', 'server': 'meinheld/0.6.1', 'date': 'Fri, 16 Mar 2018 11:59:57 GMT', 'content-type': 'application/json', 'access-control-allow-origin': '*', 'access-control-allow-credentials': 'true', 'x-powered-by': 'Flask', 'x-processed-time': '0', 'content-length': '53', 'via': '1.1 vegur'})
    b'{\n  "uuid": "693947c9-9f49-4b4a-be94-73a152ce1acb"\n}\n'

Sync usage:

>>> r = requests_core.blocking_request('GET', URL)
>>> print()
<requests_core.http_manager._async.response.HTTPResponse object at 0x103f63c88>

Installation

This is a work in progress. Don’t install it.

Release files for requestscore 0.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for requestscore 0.0.0
File Size Uploaded
requestscore-0.0.0.tar.gz 125.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for requestscore 0.0.0
File Interpreter ABI Platform
requestscore-0.0.0-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 275.3 kB

Release files / requestscore-0.0.0.tar.gz

Download URL requestscore-0.0.0.tar.gz
Size 125.3 kB
Tags Source
SHA-256 checksum
How to use checksums
a2eb176781ab3382c7ea27c1a3e3d6cace652a6a4987623f822a707d128fa272
BLAKE2b-256 checksum
How to use checksums
74667f06c74dce1cc034fc904d0468ff25391b528712b1f0f24c773546c9622e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / requestscore-0.0.0-py2.py3-none-any.whl

Download URL requestscore-0.0.0-py2.py3-none-any.whl
Size 150.0 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
f29e52a7a258d4820e39692b936ca4dfdf5a24c017ef454aae22e7cef037f026
BLAKE2b-256 checksum
How to use checksums
5173b9abaa51db8dfbf58859116e743f467af94b98acf8d21b12418321e980e9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.0.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page