Tom Christie
c9354282ba
Version 0.15.5 ( #1335 )
...
* Version 0.15.5
* Tweak ChangeLog
2020-10-01 13:57:08 +01:00
Tom Christie
3f51392bea
Add response.next_request ( #1334 )
...
* Add response.next_request
* Add response.next_request
* Add response.next_request to the docs
2020-10-01 13:52:03 +01:00
Johannes
32d37cfdf1
Small namedtuple refactor ( #1329 )
...
Plus order consistency because why not..
2020-09-27 22:15:04 +02:00
Tom Christie
a7a76fbb12
Version 0.15.4 ( #1327 )
...
* Version 0.15.4
* Update CHANGELOG
* Update CHANGELOG
* Update CHANGELOG
2020-09-25 12:34:52 +01:00
Musale Martin
815ef94ed9
Support header comparisons with dict or list. ( #1326 )
...
* Support header comparisons with dict or list.
* Add check for no headers item
* Fixup testcases affected by headers comparison using dict or list
* Update test_responses.py
Co-authored-by: Tom Christie <tom@tomchristie.com>
2020-09-25 12:28:34 +01:00
Tom Christie
666cbbdfe8
Fix automatic .read() when Response instances are created with content=<str> ( #1324 )
2020-09-25 11:29:17 +01:00
Tom Christie
320bfe1d0e
Fix warning test case ( #1322 )
2020-09-24 18:50:30 +02:00
Johannes
ac7704e78c
Remove seed-isort-config ( #1321 )
...
As of isort 5 seed-isort-config is no longer needed.
We can get rid of some explicit config too as it's now more clever.
2020-09-24 11:08:07 +01:00
Florimond Manca
24da8d40ff
Release 0.15.3 ( #1318 )
2020-09-24 11:39:02 +02:00
daa
78afd08e0f
Properly close stream on async response close ( #1316 )
2020-09-24 09:42:26 +02:00
Tom Christie
8ceb34f486
Version 0.15.2 ( #1314 )
...
* Fix response.elapsed
* Version 0.15.2
2020-09-23 11:28:22 +01:00
Tom Christie
befa57c6f9
Fix response.elapsed ( #1313 )
2020-09-23 11:26:12 +01:00
Tom Christie
d25f2bfeff
Fix stream unsetting auth ( #1312 )
...
* Fix ASGITransport path escaping
* Add failing test case for auth with streaming
* Fix .stream setting auth=None
2020-09-23 11:25:54 +01:00
emlazzarin
257b8fab6a
update arg name to max_keepalive_connections ( #1309 )
...
The old name `max_keepalive` was removed recently, so this updates the docs.
2020-09-23 10:42:21 +01:00
Tom Christie
27e67b32e9
Version 0.15.1 ( #1308 )
...
* Update CHANGELOG.md
* Update __version__.py
2020-09-23 11:12:50 +02:00
Tom Christie
e53f995994
Fix ASGITransport path escaping ( #1307 )
2020-09-23 09:37:19 +01:00
Tom Christie
c923f1af91
Update docs for 0.15 ( #1306 )
2020-09-22 11:57:14 +01:00
Tom Christie
a63b038267
Include 0.15.0 release date. ( #1305 )
2020-09-22 11:51:52 +01:00
Tom Christie
5d11756585
Include curio support in CHANGELOG ( #1304 )
2020-09-22 11:49:33 +01:00
Tom Christie
f932af9172
Version 0.15.0 ( #1301 )
...
* Version 0.15.0
* Update CHANGELOG.md
Co-authored-by: Jamie Hewland <jamie.hewland@hpe.com>
* Escalate deprecations into removals.
* Deprecate overly verbose timeout parameter names
* Fully deprecate max_keepalive in favour of explicit max_keepalive_connections
* Fully deprecate PoolLimits in favour of Limits
* Deprecate instantiating 'Timeout' without fully explicit values
* Include deprecation notes in changelog
* Use httpcore 0.11.x
Co-authored-by: Jamie Hewland <jamie.hewland@hpe.com>
2020-09-22 11:44:28 +01:00
Tom Christie
8e4a8a1c73
Finesse URL properties ( #1285 )
...
* url.userinfo should be URL encoded bytes
* Neater copy_with implementation
* Finesse API around URL properties and copy_with
* Docstring for URL, and drop url.authority
* Support url.copy_with(raw_path=...)
* Docstrings on URL methods
* Tweak docstring
2020-09-21 11:35:25 +01:00
Tom Christie
f3c29416f1
Support Response(text=...), Response(html=...), Response(json=...) ( #1297 )
...
* Refactor content_streams internally
* Tidy up multipart
* Use ByteStream annotation internally
* Support Response(text=...), Response(html=...), Response(json=...)
* Add tests for Response(text=..., html=..., json=...)
2020-09-21 11:19:19 +01:00
Tom Christie
8ee08afe96
Update _client.py ( #1300 )
2020-09-18 14:17:03 +01:00
Tom Christie
d8050ed753
Neater Host header logic on redirects ( #1299 )
2020-09-18 12:00:43 +01:00
Tom Christie
ed27682686
NetRC lookups should use host, not host+port ( #1298 )
2020-09-18 11:50:13 +01:00
Tom Christie
354c4cac1f
Refactor content streams ( #1296 )
...
* Refactor content_streams internally
* Tidy up multipart
* Use ByteStream annotation internally
2020-09-18 10:50:15 +01:00
Tom Christie
fbb21fb1ae
Drop ContentStream ( #1295 )
...
* Drop ContentStream
2020-09-18 08:41:09 +01:00
Tom Christie
e1f7791e97
Requests from transport API ( #1293 )
...
* Refactoring to support instantiating requests from transport API
* Minor refactoring
2020-09-17 11:59:42 +01:00
Tom Christie
09f94edd93
encode -> encode_request ( #1292 )
2020-09-17 09:33:36 +01:00
Tom Christie
ff0febbaa9
Update README.md ( #1291 )
...
* Update README.md
* Update index.md
2020-09-17 09:11:41 +01:00
Stephen Brown II
a394df59da
Fix function name in event hooks docs ( #1290 )
2020-09-16 09:45:20 +08:00
Tom Christie
feb404f86b
Seperate content=... and data=... parameters ( #1266 )
...
* Seperate content=... and data=... parameters
* Update compatibility.md
2020-09-15 13:36:10 +01:00
Tom Christie
54f7708e2b
Event hooks ( #1246 )
...
* Add EventHooks internal datastructure
* Add support for 'request' and 'response' event hooks
* Support Client.event_hooks property
* Handle exceptions raised by response event hooks
* Docs for event hooks
* Only support 'request' and 'response' event hooks
* Add event_hooks to top-level API
* Event hooks
* Formatting
* Formatting
* Fix up event hooks test
* Add test case to confirm that redirects/event hooks don't currently play together correctly
* Refactor test cases
* Make response.request clear in response event hooks docs
* Drop merge marker
* Request event hook runs as soon as we have an auth-constructed request
2020-09-15 12:05:39 +01:00
Tom Christie
d0fe113945
Drop chardet ( #1269 )
...
* Internal refactoring to swap auth/redirects ordering
* Drop chardet for charset detection
* Drop chardet in favour of simpler charset autodetection
* Revert unintentionally included changes
* Update test case
* Refactor to prefer different decoding style
* Update text decoding docs/docstrings
* Resolve typo
* Update docs/quickstart.md
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
2020-09-15 11:20:19 +01:00
Tom Christie
2d6c30d061
Refactor test_auth.py to use MockTransport class. ( #1288 )
...
* Use tests.utils.MockTransport
* Use tests.utils.MockTransport
2020-09-14 17:44:05 +01:00
cdeler
62c6c1c8ad
Refactoring of models api ( #1284 )
...
* Made Request.prepare private (i.e. renamed it to _prepare)
* Added bytes as a new possible QueryParamTypes
2020-09-14 12:16:45 +01:00
Tom Christie
b58bd8e8e5
Pin flake8-pie ( #1286 )
...
* Pin `flake8-pie`
* Update requirements.txt
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
2020-09-12 19:41:47 +01:00
Tom Christie
c2afd2d9bf
Refactor tests to use MockTransport(<handler_function>) ( #1281 )
...
* Support Response(content=<bytes iterator>)
* Update test for merged master
* Add MockTransport for test cases
* Use MockTransport for redirect tests
* Reduce change footprint
* Reduce change footprint
* Clean up headers slightly
* Update requirements.txt
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
2020-09-12 11:16:10 +01:00
Tom Christie
8a5050ea41
Refactor to use isinstance(..., typing.Iterator) ( #1282 )
2020-09-11 14:37:51 +01:00
Tom Christie
5ee6135256
Support Response(content=<bytes iterator>) ( #1265 )
...
* Support Response(content=<bytes iterator>)
* Update test for merged master
2020-09-11 10:28:18 +01:00
Bart
4bd08bed22
Update compatibility.md: mention differing query parameter handling ( #1262 )
...
* Update compatibility.md
* Update docs/compatibility.md
* Update docs/compatibility.md
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
Co-authored-by: Tom Christie <tom@tomchristie.com>
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
2020-09-10 21:22:14 +02:00
Tom Christie
6006721c6d
Minor decoder refactoring. ( #1276 )
...
* Switch auth/redirect methods to follow flow of execution better
* Drop response.decoder property
* Decoder -> ContentDecoder
* Decoder -> ContentDecoder
2020-09-10 15:10:31 +01:00
Tom Christie
59074c7bc0
Progress examples ( #1272 )
...
* Progress examples
* Update advanced.md
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
2020-09-10 12:28:08 +01:00
Tom Christie
930f3773e2
Switch auth/redirect methods to follow flow of execution better ( #1273 )
2020-09-10 12:44:36 +02:00
cdeler
ed16eb3a3d
Add progress to streaming download ( #1268 )
...
* Added last_raw_chunk_size to the Response object (#1208 )
* Added example with progress bar (#1208 )
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
* Apply suggestions from code review
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
* PR review
Changed last_raw_chunk_size to num_bytes_downloaded ;
Edited the example according to documentaion
* Update docs/advanced.md
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
* Update docs/advanced.md
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
* Update docs/advanced.md
* Update docs/advanced.md
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
Co-authored-by: Tom Christie <tom@tomchristie.com>
2020-09-10 12:16:00 +03:00
Tom Christie
4d950e5780
Swap auth/redirects ordering ( #1267 )
...
* Internal refactoring to swap auth/redirects ordering
* Test for auth with cross domain redirect
2020-09-10 09:12:05 +01:00
Florimond Manca
016e4ee210
Add support for sync-specific or async-specific auth flows ( #1217 )
...
* Add support for async auth flows
* Move body logic to Auth, add sync_auth_flow, add NoAuth
* Update tests
* Stick to next() / __anext__()
* Fix undefined name errors
* Add docs
* Add unit tests for auth classes
Co-authored-by: Tom Christie <tom@tomchristie.com>
2020-09-09 14:37:20 +01:00
cdeler
15187e7c21
Fixed test_multiple_set_cookie ( #1270 )
...
* Fixed test_multiple_set_cookie
* Update test_cookies.py
Co-authored-by: Tom Christie <tom@tomchristie.com>
2020-09-09 10:01:39 +01:00
Tom Christie
a783fe5758
Drop request.timer attribute. ( #1249 )
...
* Drop request.timer attribute
* Response(..., elapsed_func=...)
2020-09-07 09:06:14 +01:00
cdeler
78f24203ce
Edited documentation about proxy-envs usage ( #404 ) ( #1257 )
...
* Edited documentation about proxy-envs usage (#404 )
* PR review (#404 )
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
* PR review (#404 )
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
* Fix typo
Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
2020-09-06 14:52:37 +03:00