Requests-Text is a transport adapter for use with the Requests Python library to allow text under text:// URLs.
To use:
import requests
from requests_text import TextAdapter
s = requests.Session()
s.mount('text://', TextAdapter())
resp = s.get('text://sometext')
Features
Will open and read text
Might set a Content-Length header
That’s about it
Contributions welcome! Feel free to open a pull request against https://github.com/huakim/python-requests-text
License
To maximise compatibility with Requests, this code is licensed under the Apache license. See LICENSE for more details.
Metadata
Release files for requests-text 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| requests_text-1.0.2.tar.gz | 3.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| requests_text-1.0.2-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details |
Total release size: 6.0 kB
Release files / requests_text-1.0.2.tar.gz
| Download URL | requests_text-1.0.2.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b9e5359b93ef0d9e51d470a7c6a532860adae8cc4deedcab9e032d2f01066fd9
|
|
BLAKE2b-256 checksum How to use checksums |
d89f17284a72bd46647b8042a51d2b7cffd5997bf41112f07211142d74b6d7f6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Release files / requests_text-1.0.2-py2.py3-none-any.whl
| Download URL | requests_text-1.0.2-py2.py3-none-any.whl |
|---|---|
| Size | 2.7 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
e591e1e6ba684b18dd802dd747a10ccf2f0cbd0d7bdc6e1af3c83bcb0e1d5eae
|
|
BLAKE2b-256 checksum How to use checksums |
2dd9143568fe4bbf41fc8171c165c59d512482405300bec437dd5782241826d7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|