Update to 2.32.3 (rhbz#2281881) and fix CVE-2024-35195 (rhbz#2282205)
This commit is contained in:
parent
2e1de3d0e8
commit
89e46163b4
6 changed files with 67 additions and 84 deletions
|
|
@ -5,8 +5,8 @@
|
|||
%bcond extras %{undefined rhel}
|
||||
|
||||
Name: python-requests
|
||||
Version: 2.31.0
|
||||
Release: 7%{?dist}
|
||||
Version: 2.32.3
|
||||
Release: 1%{?dist}
|
||||
Summary: HTTP library, written in Python, for human beings
|
||||
|
||||
License: Apache-2.0
|
||||
|
|
@ -24,9 +24,6 @@ Patch: system-certs.patch
|
|||
# This change is backported also into RHEL 9.4 (via CS)
|
||||
Patch: support_IPv6_CIDR_in_no_proxy.patch
|
||||
|
||||
# Fix FTBFS (test_redirecting_to_bad_url)
|
||||
Patch: https://github.com/psf/requests/commit/bf24b7.patch
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
%if %{with tests}
|
||||
|
|
@ -66,17 +63,13 @@ designed to make HTTP requests easy for developers.
|
|||
%autosetup -p1 -n requests-%{version}
|
||||
|
||||
# env shebang in nonexecutable file
|
||||
sed -i '/#!\/usr\/.*python/d' requests/certs.py
|
||||
sed -i '/#!\/usr\/.*python/d' src/requests/certs.py
|
||||
|
||||
# Some doctests use the internet and fail to pass in Koji. Since doctests don't have names, I don't
|
||||
# know a way to skip them. We also don't want to patch them out, because patching them out will
|
||||
# change the docs. Thus, we set pytest not to run doctests at all.
|
||||
sed -i 's/ --doctest-modules//' pyproject.toml
|
||||
|
||||
# Fix compatibility with pytest 8
|
||||
# Upstream report: https://github.com/psf/requests/issues/6679
|
||||
sed -i "/pytest.warns/s/None//" tests/test_requests.py
|
||||
|
||||
|
||||
%build
|
||||
%pyproject_wheel
|
||||
|
|
@ -90,8 +83,9 @@ sed -i "/pytest.warns/s/None//" tests/test_requests.py
|
|||
%check
|
||||
%pyproject_check_import
|
||||
%if %{with tests}
|
||||
# test_unicode_header_name - reported: https://github.com/psf/requests/issues/6734
|
||||
# test_use_proxy_from_environment needs pysocks
|
||||
%pytest -v tests %{!?with_extras:-k "not test_use_proxy_from_environment"}
|
||||
%pytest -v tests -k "not test_unicode_header_name %{!?with_extras:and not test_use_proxy_from_environment}"
|
||||
%endif
|
||||
|
||||
|
||||
|
|
@ -101,6 +95,10 @@ sed -i "/pytest.warns/s/None//" tests/test_requests.py
|
|||
|
||||
|
||||
%changelog
|
||||
* Wed Jun 19 2024 Lumír Balhar <lbalhar@redhat.com> - 2.32.3-1
|
||||
- Update to 2.32.3 (rhbz#2281881)
|
||||
- Fix for CVE-2024-35195 (rhbz#2282205)
|
||||
|
||||
* Sun Jun 09 2024 Python Maint <python-maint@redhat.com> - 2.31.0-7
|
||||
- Rebuilt for Python 3.13
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue