15
0
forked from pool/python-httpx

Accepting request 900750 from home:alarrosa:branches:devel:languages:python

- Update to 0.18.2
  * Added
    - Support for Python 3.10. (Pull #1687)
    - Expose httpx.USE_CLIENT_DEFAULT, used as the default to auth
      and timeout parameters in request methods.
    - Support HTTP/2 "prior knowledge", using
      httpx.Client(http1=False, http2=True).
  * Fixed
    - Clean up some cases where warnings were being issued.
    - Prefer Content-Length over Transfer-Encoding: chunked for
      content= cases.
- Update to 0.18.1
  * Changed
    - Update brotli support to use the brotlicffi package
    - Ensure that Request(..., stream=...) does not auto-generate
      any headers on the request instance.
  * Fixed
    - Pass through timeout=... in top-level httpx.stream()
      function.
    - Map httpcore transport close exceptions to httpx exceptions.
- Add patch (submitted to upstream at gh#encode/httpx#1669) to add
  a pytest marker so we can disable the tests that use the network
  in %check:
  * 0001-Add-a-network-pytest-mark-for-tests-that-use-the-network.patch

OBS-URL: https://build.opensuse.org/request/show/900750
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-httpx?expand=0&rev=3
This commit is contained in:
2021-06-18 11:18:04 +00:00
committed by Git OBS Bridge
parent 79e678f057
commit ab0f76ecff
5 changed files with 104 additions and 8 deletions

View File

@@ -20,17 +20,19 @@
%define skip_python2 1
%define skip_python36 1
Name: python-httpx
Version: 0.18.0
Version: 0.18.2
Release: 0
Summary: Python HTTP client with async support
License: BSD-3-Clause
Group: Development/Languages/Python
URL: https://github.com/encode/httpx
Source: https://github.com/encode/httpx/archive/%{version}.tar.gz#/httpx-%{version}.tar.gz
# PATCH-FIX-UPSTREAM alarrosa@suse.com (gh#encode/httpx#1669)
Patch0: 0001-Add-a-network-pytest-mark-for-tests-that-use-the-network.patch
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-Brotli >= 0.7.0
Requires: python-brotlicffi
Requires: python-certifi
Requires: python-chardet >= 3.0
Requires: python-h11 >= 0.8.0
@@ -42,7 +44,7 @@ Requires: python-rfc3986 >= 1.3
Requires: python-sniffio
BuildArch: noarch
# SECTION test requirements
BuildRequires: %{python_module Brotli >= 0.7.0}
BuildRequires: %{python_module brotlicffi}
BuildRequires: %{python_module async_generator}
BuildRequires: %{python_module certifi}
BuildRequires: %{python_module chardet >= 3.0}
@@ -68,6 +70,7 @@ Python HTTP client with async support.
%prep
%setup -q -n httpx-%{version}
%patch0 -p1
rm setup.cfg
%build
@@ -78,8 +81,7 @@ rm setup.cfg
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
# test_start_tls_on_*_socket_stream and test_connect_timeout require network
%pytest -k 'not (test_start_tls_on_tcp_socket_stream or test_start_tls_on_uds_socket_stream or test_connect_timeout or test_async_proxy_close or test_sync_proxy_close)'
%pytest -k 'not network'
%files %{python_files}
%doc CHANGELOG.md README.md