A mimic inspired by the session feature in Requests, it adds support to Tornado that allows you to persist context such as cookies and other parameters across requests’ fetching from tornado.httpclient.
THIS IS SESSION ABOUT CLIENT, NOT SERVER!
Installation
pip install tornado-httpclient-session
Usage
from tornado.httpclient import HTTPClient
from httpclient_session import Session
s = Session(HTTPClient) # AsyncHTTPClient default
r = s.fetch('https://github.com')
print(r.headers['set-cookie']) # Inspect cookies returnd from Github
r = s.fetch('https://github.com') # Fetching carrys cookies
print(r.request.headers['cookie']) # Inspect cookies attached
Testing
python setup.py test
Or for all supported environments:
tox
Development Progress
Persistences of:
Cookies ✔
Referrer ✘
Authorization ✘
Any Suggestions Welcome!
Metadata
Release files for tornado-httpclient-session 0.2.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| tornado-httpclient-session-0.2.5.tar.gz | 7.9 kB | Without provenance | Details |
Release files / tornado-httpclient-session-0.2.5.tar.gz
| Download URL | tornado-httpclient-session-0.2.5.tar.gz |
|---|---|
| Size | 7.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
761fd19b24188cd47f48aa749060463af94db3342e1cb53f328b37b91b2d8b8b
|
|
BLAKE2b-256 checksum How to use checksums |
cfb3614eaf28f80adbf13d69c9505a5053e190b9c5095017b058ed188ae7d9e8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for tornado-httpclient-session 0.2.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.