Switch from upstream deprecated pytoml to toml
This commit is contained in:
parent
9789724e07
commit
ed5dd772f3
@ -57,7 +57,7 @@ fi
|
||||
%{-e:%{expand:%global toxenv %{-e*}}}
|
||||
echo 'python3-devel'
|
||||
echo 'python3dist(packaging)'
|
||||
echo 'python3dist(pytoml)'
|
||||
echo 'python3dist(toml)'
|
||||
# setuptools assumes no pre-existing dist-info
|
||||
rm -rfv *.dist-info/ >&2
|
||||
if [ -f %{__python3} ]; then
|
||||
|
@ -6,7 +6,7 @@ License: MIT
|
||||
|
||||
# Keep the version at zero and increment only release
|
||||
Version: 0
|
||||
Release: 15%{?dist}
|
||||
Release: 16%{?dist}
|
||||
|
||||
# Macro files
|
||||
Source001: macros.pyproject
|
||||
@ -39,7 +39,7 @@ Requires: python3-devel
|
||||
# But those are also always in the output of %%generate_buildrequires
|
||||
# in order to be removable in the future
|
||||
Requires: python3dist(packaging)
|
||||
Requires: python3dist(pytoml)
|
||||
Requires: python3dist(toml)
|
||||
|
||||
# This is not output from %%generate_buildrequires to work around:
|
||||
# https://github.com/rpm-software-management/mock/issues/336
|
||||
@ -54,9 +54,9 @@ BuildRequires: python3dist(packaging)
|
||||
# https://github.com/rpm-software-management/mock/issues/336
|
||||
BuildRequires: (python3dist(importlib-metadata) if python3 < 3.8)
|
||||
%endif
|
||||
BuildRequires: python3dist(pytoml)
|
||||
BuildRequires: python3dist(pip)
|
||||
BuildRequires: python3dist(setuptools)
|
||||
BuildRequires: python3dist(toml)
|
||||
BuildRequires: python3dist(tox-current-env) >= 0.0.2
|
||||
BuildRequires: python3dist(wheel)
|
||||
%endif
|
||||
@ -100,6 +100,9 @@ install -m 644 pyproject_save_files.py %{buildroot}%{_rpmconfigdir}/redhat/
|
||||
%license LICENSE
|
||||
|
||||
%changelog
|
||||
* Fri Jun 19 2020 Miro Hrončok <mhroncok@redhat.com> - 0-16
|
||||
- Switch from upstream deprecated pytoml to toml
|
||||
|
||||
* Thu May 07 2020 Tomas Hrnciar <thrnciar@redhat.com> - 0-15
|
||||
- Adapt %%pyproject_install not to create a PEP 610 direct_url.json file
|
||||
|
||||
|
@ -23,7 +23,7 @@ class EndPass(Exception):
|
||||
|
||||
|
||||
try:
|
||||
import pytoml
|
||||
import toml
|
||||
from packaging.requirements import Requirement, InvalidRequirement
|
||||
from packaging.utils import canonicalize_name, canonicalize_version
|
||||
try:
|
||||
@ -129,7 +129,7 @@ def get_backend(requirements):
|
||||
pyproject_data = {}
|
||||
else:
|
||||
with f:
|
||||
pyproject_data = pytoml.load(f)
|
||||
pyproject_data = toml.load(f)
|
||||
|
||||
buildsystem_data = pyproject_data.get('build-system', {})
|
||||
requirements.extend(
|
||||
|
Loading…
Reference in New Issue
Block a user