Commit Graph

1520 Commits

Author SHA1 Message Date
Tom Christie
ec365c0e8e
Check disconnections on connection reacquiry (#145)
* Detect EOF signaling remote server closed connection

Raise ConnectionClosedByRemote and handle on `send`

* Fix linting

* Use existing NotConnected exception

* Add `Reader.is_connection_dropped` method

* Check connection before sending h11 events as well

* Add test covering connection lost before reading response content

* Check for connection closed on acquiring it from the pool

* Clean up ConnectionPool logic around reaquiry of connections
2019-07-25 22:52:41 +01:00
Stephen Brown II
8db36ed6a5 Allow string comparison for URL().__eq__ (#139) 2019-07-24 16:28:16 +01:00
Stephen Brown II
37df46a83b Additional HTTP Status Codes 418, 451 (#135) 2019-07-22 15:13:00 -05:00
Tom Christie
edd702955e
Update README.md 2019-07-19 15:44:17 +01:00
Tom Christie
7511d7a562
Update README.md 2019-07-19 15:43:04 +01:00
Tom Christie
04501424cd
Update README.md 2019-07-19 15:41:18 +01:00
Tom Christie
890a800b9b
Update README.md 2019-07-19 15:40:32 +01:00
Tom Christie
f7c5378ebd
Update README.md 2019-07-19 15:38:53 +01:00
Tom Christie
44759609aa
Update README.md 2019-07-19 15:38:08 +01:00
Tom Christie
0f54645f95
Update README.md 2019-07-19 15:37:25 +01:00
Tom Christie
95db220e22
Update README.md 2019-07-19 15:37:02 +01:00
Tom Christie
17bb165042
Branding updates for httpx (#130) 2019-07-19 15:36:36 +01:00
Tom Christie
219ece023a Rename -> httpx 2019-07-19 15:20:15 +01:00
Tom Christie
2d09d5b36c
Renaming -> httpx (#129)
* Renaming -> httpx

* Renaming to httpx
2019-07-19 15:15:16 +01:00
ambrozic
0e8dae4815 Multipart data values encoding (#121)
* multipart data values encoding (#119)

* Update test_multipart.py
2019-07-18 12:00:02 +01:00
Seth Michael Larson
c1044cab84 Start using flake8, fix lint issues (#126) 2019-07-18 11:41:50 +01:00
Seth Michael Larson
ba83e29aee Support client cert passwords, new TLS options (#118)
* Support client cert passwords, new TLS options

* Update test_config.py

* Switch to try-except for post_handshake_auth=True

SSLContext.post_handshake_auth raises AttributeError if the property is available but cannot be written to (needs OpenSSL 1.1.1+)

* Also try-except for hostname_checks_common_name=False

* Custom implementation of trustme.CA() that emits encrypted PKs

* lint

* Split name of test

* Updates from review comments

* Don't load default CAs yet
2019-07-16 10:08:57 +01:00
Yeray Diaz Diaz
5442006a41 Encoding detection in Response.json (#116)
* Use response text on `json`

Pass kwargs to the loads call

* Add failing test demonstrating corner case

* Copy `guess_json_utf` function from requests

* "Fix" type hinting and lint

* Actually add tests_utils.py
2019-07-11 17:14:58 +01:00
Tom Christie
561fb84248 Version 0.6.7 2019-07-08 15:58:44 +01:00
Tom Christie
025240c3b3
Check for connection aliveness on pool re-acquiry (#111)
* Check for connection aliveness on pool re-acquiry

* Test for connection re-acquiry with HTTP/2

* nocover on HTTP/1.1 ConnectionResetError, since we're testing the equivelent on HTTP/2

* Fix setup.py to read version from __version__
2019-07-08 15:57:29 +01:00
Tom Christie
fe1f9ed119
Minor tweaks in line with requests behavior (#110) 2019-07-03 10:33:38 +01:00
Tom Christie
fe71e939c3 Version 0.6.5 2019-06-27 16:46:58 +01:00
Tom Christie
5539b69ac2
Include host header directly (#109)
* Improve HTTP protocol detection

* Include host header when request is instantiated

* Add raise_app_exceptions

* Tweaks to ASGI dispatching

* Linting

* Don't quote multipart values

* Tweak decoder ordering in header

* Allow str data in request bodys
2019-06-27 16:46:13 +01:00
Tom Christie
04cb3a6d98
Improve HTTP protocol detection (#107) 2019-06-25 17:13:16 +01:00
Tom Christie
5326cd1a20
Version 0.6.4 (#105)
* Read/Write timeout modes

* Read/Write timeout modes

* Tweaks for read/write timeout modes

* Version 0.6.4

* Make slow_response slower for timeout test
2019-06-25 13:24:12 +01:00
Tom Christie
f4f05e343c
Read/Write timeout modes (#104)
* Read/Write timeout modes

* Read/Write timeout modes
2019-06-25 12:54:14 +01:00
Tom Christie
d3a12e73c0 Version 0.6.3 2019-06-24 16:54:24 +01:00
Tom Christie
b9c8a1505e
Handle early connection closes (#103)
* Refactoring h11 implementation

* More h11 refactoring

* Support early connection closes on H11 connections

* Tweak comment

* Refactor concurrent read/writes

* Drop WriteTimeout masking

* Linting

* Use concurrent read/writes for HTTP2

* Push background sending into ConcurrencyBackend
2019-06-24 16:53:42 +01:00
updatatoday
f9e3ad4c16 Fixed response repr. (#101)
* Fixed response repr.

* Fixed response repr tests.
2019-06-23 11:37:00 +01:00
Tom Christie
9930de8091
Use urllib3's DEFAULT_CIPHERS for ssl config (#100) 2019-06-23 11:24:17 +01:00
Tom Christie
7ff8483fc8 Version 0.6.1 2019-06-21 16:44:40 +01:00
Tom Christie
9d5aaff5bc Support Client(base_url=...) 2019-06-21 15:03:01 +01:00
Tom Christie
2af17c8d7a Version 0.6.0 2019-06-21 13:50:19 +01:00
Tom Christie
444c6b8870
Honour 'local_flow_control_window' (#98) 2019-06-21 13:49:25 +01:00
Tom Christie
87e199e6bd Tweak README 2019-06-18 16:02:18 +01:00
Tom Christie
9f192bbf0b Version 0.5.0 2019-06-18 15:54:41 +01:00
Tom Christie
bb8697011d
Support WSGI and ASGI apps. (#94)
* Add 'Client(app=...)' support

* Add ASGI support with Client(app=app)

* Improve exc cases when using client with ASGI

* Tighten up exception handling when using as a test client

* Fix up stream I/O for WSGI/ASGI apps

* Docs for WSGI/ASGI integration
2019-06-18 15:53:33 +01:00
Tom Christie
fdc4ab2a89 Tweak compat docs 2019-06-17 17:28:27 +01:00
Tom Christie
606e7f0b8d Version 0.1.1 2019-06-17 16:55:24 +01:00
Tom Christie
56a7943206
Int status codes (#92)
* Use plain int for response.status_code

* Linting
2019-06-17 16:53:39 +01:00
Tom Christie
920925ca00 Version 0.1 2019-06-17 14:52:44 +01:00
Tom Christie
d21e3ab2f0 Add multipart docs 2019-06-17 14:51:40 +01:00
Tom Christie
6a44b05e4d
Multipart support (#90)
* Multipart support

* Test compat with 3.6
2019-06-17 14:38:24 +01:00
Tom Christie
7c6fb5c6ca
Tweaks (#89)
* Close redirect responses

* History should not be reverse-order

* History should not be reverse-order

* Docs updates
2019-06-13 16:19:39 +01:00
Tom Christie
3ca9a74813
Close redirect responses (#88) 2019-06-13 14:38:56 +01:00
Tom Christie
d5d726f66a Add Cookies docs 2019-06-13 14:03:22 +01:00
Tom Christie
f296e6ded9 'For Python 3' 2019-06-12 16:25:48 +01:00
Tom Christie
c2c87e14f0 Docs links 2019-06-12 16:24:33 +01:00
Tom Christie
a40758834c Merge branch 'master' of https://github.com/encode/http3 2019-06-12 16:06:17 +01:00
Tom Christie
60dca3da39 Docs tweaks 2019-06-12 16:06:09 +01:00