From 9e957b0cff6d88dacf246a0015cb0b0e35e66f60c29680e85842a39d4ba5a807 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Wed, 25 Oct 2023 12:35:45 +0000 Subject: [PATCH] - Update to 0.18.0: - Add support for HTTPS proxies. - Handle sni_hostname extension with SOCKS proxy. - Change the type of Extensions from Mapping[Str, Any] to MutableMapping[Str, Any]. - Handle HTTP/1.1 half-closed connections gracefully. - Drop Python 3.7 support. - Update httpcore-allow-deprecationwarnings-test.patch OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-httpcore?expand=0&rev=26 --- httpcore-0.17.3.tar.gz | 3 -- httpcore-0.18.0.tar.gz | 3 ++ httpcore-allow-deprecationwarnings-test.patch | 36 ++++++++++--------- python-httpcore.changes | 12 +++++++ python-httpcore.spec | 11 +++--- 5 files changed, 42 insertions(+), 23 deletions(-) delete mode 100644 httpcore-0.17.3.tar.gz create mode 100644 httpcore-0.18.0.tar.gz diff --git a/httpcore-0.17.3.tar.gz b/httpcore-0.17.3.tar.gz deleted file mode 100644 index 65d0537..0000000 --- a/httpcore-0.17.3.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ece7948107e9214c2202b32b228ddc9391c76d87279aa38ade1b5ff575d35a05 -size 91500 diff --git a/httpcore-0.18.0.tar.gz b/httpcore-0.18.0.tar.gz new file mode 100644 index 0000000..0c46b70 --- /dev/null +++ b/httpcore-0.18.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0280df5defe0091029f2dbbfb50c4107597e78f8cc0d24577c4d99acb6621692 +size 94594 diff --git a/httpcore-allow-deprecationwarnings-test.patch b/httpcore-allow-deprecationwarnings-test.patch index 06a6ec0..ada1e3a 100644 --- a/httpcore-allow-deprecationwarnings-test.patch +++ b/httpcore-allow-deprecationwarnings-test.patch @@ -1,17 +1,21 @@ -Index: httpcore-0.16.3/setup.cfg -=================================================================== ---- httpcore-0.16.3.orig/setup.cfg -+++ httpcore-0.16.3/setup.cfg -@@ -30,6 +30,12 @@ markers = - copied_from(source, changes=None): mark test as copied from somewhere else, along with a description of changes made to accodomate e.g. our test setup - filterwarnings = - error -+ # requires anyio 4 with trio 0.22: https://github.com/agronholm/anyio/issues/470 -+ ignore:trio.MultiError is deprecated -+ # fixed by pytest-httpbin (2.0 not released yet): https://github.com/encode/httpcore/pull/511 -+ ignore:unclosed <(socket\.socket|ssl\.SSLSocket) .*:ResourceWarning -+ ignore:ssl\.wrap_socket\(\) is deprecated, use SSLContext\.wrap_socket\(\):DeprecationWarning -+ ignore:ssl\.PROTOCOL_TLS is deprecated:DeprecationWarning +--- + pyproject.toml | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -86,7 +86,13 @@ ignore_missing_imports = true + [tool.pytest.ini_options] + addopts = ["-rxXs", "--strict-config", "--strict-markers"] + markers = ["copied_from(source, changes=None): mark test as copied from somewhere else, along with a description of changes made to accodomate e.g. our test setup"] +-filterwarnings = ["error"] ++filterwarnings = [ ++ "error", ++ "ignore:trio.MultiError is deprecated", ++ "ignore:unclosed <(socket.socket|ssl.SSLSocket) .*:ResourceWarning", ++ "ignore:ssl.wrap_socket() is deprecated, use SSLContext.wrap_socket():DeprecationWarning", ++ "ignore:ssl.PROTOCOL_TLS is deprecated:DeprecationWarning" ++] - [coverage:run] - omit = venv/*, httpcore/_sync/* + [tool.coverage.run] + omit = [ diff --git a/python-httpcore.changes b/python-httpcore.changes index 00d3e70..0117a86 100644 --- a/python-httpcore.changes +++ b/python-httpcore.changes @@ -1,3 +1,15 @@ +------------------------------------------------------------------- +Wed Oct 25 11:30:12 UTC 2023 - Matej Cepl + +- Update to 0.18.0: + - Add support for HTTPS proxies. + - Handle sni_hostname extension with SOCKS proxy. + - Change the type of Extensions from Mapping[Str, Any] to + MutableMapping[Str, Any]. + - Handle HTTP/1.1 half-closed connections gracefully. + - Drop Python 3.7 support. +- Update httpcore-allow-deprecationwarnings-test.patch + ------------------------------------------------------------------- Sun Sep 10 11:05:24 UTC 2023 - Torsten Gruner diff --git a/python-httpcore.spec b/python-httpcore.spec index b60f206..d537bf0 100644 --- a/python-httpcore.spec +++ b/python-httpcore.spec @@ -27,7 +27,7 @@ %{?sle15_python_module_pythons} Name: python-httpcore%{psuffix} -Version: 0.17.3 +Version: 0.18.0 Release: 0 Summary: Minimal low-level Python HTTP client License: BSD-3-Clause @@ -36,7 +36,10 @@ Source: https://github.com/encode/httpcore/archive/%{version}.tar.gz#/ht # PATCH-FIX-UPSTREAM httpcore-allow-deprecationwarnings-test.patch gh#encode/httpcore#511, gh#agronholm/anyio#470 Patch1: httpcore-allow-deprecationwarnings-test.patch BuildRequires: %{python_module base >= 3.7} -BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module hatch-fancy-pypi-readme} +BuildRequires: %{python_module hatchling} +BuildRequires: %{python_module pip} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-certifi @@ -68,10 +71,10 @@ Python minimal low-level HTTP client. %if !%{with test} %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %endif