Accepting request 984778 from home:mjacob:branches:devel:languages:python

- Patch PKG-INFO to avoid pip failing on Python 3.6 with 
  `ERROR: Package 'MarkupSafe' requires a different Python:
   3.6.15 not in '>=3.7'`.

OBS-URL: https://build.opensuse.org/request/show/984778
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-MarkupSafe?expand=0&rev=39
This commit is contained in:
Matej Cepl 2022-06-27 07:52:22 +00:00 committed by Git OBS Bridge
parent 528d63b8d6
commit 7bf58263d5
2 changed files with 11 additions and 0 deletions

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Fri Jun 24 02:55:18 UTC 2022 - Manuel Jacob <me@manueljacob.de>
- Patch PKG-INFO to avoid pip failing on Python 3.6 with
`ERROR: Package 'MarkupSafe' requires a different Python:
3.6.15 not in '>=3.7'`.
-------------------------------------------------------------------
Thu Jun 9 07:59:18 UTC 2022 - Andreas Schneider <asn@cryptomilk.org>

View File

@ -57,6 +57,10 @@ export CFLAGS="%{optflags}"
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitearch}
%python_expand rm %{buildroot}%{$python_sitearch}/markupsafe/_speedups.c
# Upstream changed the Python package metadata to require Python 3.7, but the tests pass on Python 3.6.
%if %python_version_nodots == 36
%python_expand sed 's/Requires-Python: >=3.7/Requires-Python: >=3.6/' -i %{buildroot}%{python_sitearch}/MarkupSafe-%{version}-py3.6.egg-info/PKG-INFO
%endif
%if %{with test}
%check