pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/www/py-httpcore py-httpcore: updated to 0.13.3



details:   https://anonhg.NetBSD.org/pkgsrc/rev/3bca3b322869
branches:  trunk
changeset: 452297:3bca3b322869
user:      adam <adam%pkgsrc.org@localhost>
date:      Sat May 08 08:56:56 2021 +0000

description:
py-httpcore: updated to 0.13.3

0.13.3 (May 6th, 2021)

Added

- Support HTTP/2 prior knowledge, using `httpcore.SyncConnectionPool(http1=False)`.

Fixed

- Handle cases where environment does not provide `select.poll` support.

0.13.2 (April 29th, 2021)

Added

- Improve error message for specific case of `RemoteProtocolError` where server disconnects without sending a response.

0.13.1 (April 28th, 2021)

Fixed

- More resiliant testing for closed connections.
- Don't raise exceptions on ungraceful connection closes.

0.13.0 (April 21st, 2021)

The 0.13 release updates the core API in order to match the HTTPX Transport API,
introduced in HTTPX 0.18 onwards.

An example of making requests with the new interface is:

```python
with httpcore.SyncConnectionPool() as http:
    status_code, headers, stream, extensions = http.handle_request(
        method=b'GET',
        url=(b'https', b'example.org', 443, b'/'),
        headers=[(b'host', b'example.org'), (b'user-agent', b'httpcore')]
        stream=httpcore.ByteStream(b''),
        extensions={}
    )
    body = stream.read()
    print(status_code, body)
```

Changed

- The `.request()` method is now `handle_request()`.
- The `.arequest()` method is now `.handle_async_request()`.
- The `headers` argument is no longer optional.
- The `stream` argument is no longer optional.
- The `ext` argument is now named `extensions`, and is no longer optional.
- The `"reason"` extension keyword is now named `"reason_phrase"`.
- The `"reason_phrase"` and `"http_version"` extensions now use byte strings for their values.
- The `httpcore.PlainByteStream()` class becomes `httpcore.ByteStream()`.

Added

- Streams now support a `.read()` interface.

Fixed

- Task cancelation no longer leaks connections from the connection pool.

diffstat:

 www/py-httpcore/Makefile |   4 ++--
 www/py-httpcore/distinfo |  10 +++++-----
 2 files changed, 7 insertions(+), 7 deletions(-)

diffs (27 lines):

diff -r 39d5a7c6e45f -r 3bca3b322869 www/py-httpcore/Makefile
--- a/www/py-httpcore/Makefile  Sat May 08 07:16:46 2021 +0000
+++ b/www/py-httpcore/Makefile  Sat May 08 08:56:56 2021 +0000
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.5 2021/02/05 20:34:10 adam Exp $
+# $NetBSD: Makefile,v 1.6 2021/05/08 08:56:56 adam Exp $
 
-DISTNAME=      httpcore-0.12.3
+DISTNAME=      httpcore-0.13.3
 PKGNAME=       ${PYPKGPREFIX}-${DISTNAME}
 CATEGORIES=    www python
 MASTER_SITES=  ${MASTER_SITE_PYPI:=h/httpcore/}
diff -r 39d5a7c6e45f -r 3bca3b322869 www/py-httpcore/distinfo
--- a/www/py-httpcore/distinfo  Sat May 08 07:16:46 2021 +0000
+++ b/www/py-httpcore/distinfo  Sat May 08 08:56:56 2021 +0000
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.5 2021/02/05 20:34:10 adam Exp $
+$NetBSD: distinfo,v 1.6 2021/05/08 08:56:56 adam Exp $
 
-SHA1 (httpcore-0.12.3.tar.gz) = d67f3a58c969dc0099aea22a10745ec00f137059
-RMD160 (httpcore-0.12.3.tar.gz) = 7949fa14fa3b8eacf2c44c51778ccb722197a0cc
-SHA512 (httpcore-0.12.3.tar.gz) = 6e2256c7ab35e8aca6e1c8e4bc422cf34eb7395993d7df8b6bf28f2f325477a58df275e3c28c3a933488abba38b27036051b13f8826887690be2fee999f6f0dc
-Size (httpcore-0.12.3.tar.gz) = 43346 bytes
+SHA1 (httpcore-0.13.3.tar.gz) = 0510e32659e912e185f715661c9afc4e490f213e
+RMD160 (httpcore-0.13.3.tar.gz) = 82bf6bb7e4cda1b71534b301c25ad49975ed1c42
+SHA512 (httpcore-0.13.3.tar.gz) = b7177ef4e49f911ee225898235af94ea955263edf50b63778303a5a8f80448b4480899acf198c208b8bee07a7d236f06fd90f8f720b1a97651a3d706b4b4c073
+Size (httpcore-0.13.3.tar.gz) = 45292 bytes



Home | Main Index | Thread Index | Old Index