diff --git a/python-poetry-core.spec b/python-poetry-core.spec index e97bb37..f12bba7 100644 --- a/python-poetry-core.spec +++ b/python-poetry-core.spec @@ -1,15 +1,31 @@ Name: python-poetry-core Version: 1.0.3 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Poetry PEP 517 Build Backend -License: MIT + +# We bundle a lot of libraries with poetry, which itself is under MIT license. +# Here is the list of the libraries with corresponding licenses: + +# attrs: MIT +# jsonschema: MIT +# lark-parser: MIT +# packaging: ASL 2.0 or BSD +# pyparsing: MIT +# pyrsistent: MIT +# six: MIT +# tomlkit: MIT + +License: MIT and (ASL 2.0 or BSD) URL: https://github.com/python-poetry/poetry-core Source0: %{url}/archive/%{version}/poetry-core-%{version}.tar.gz # This patch moves the vendored requires definition # from vendors/pyproject.toml to pyproject.toml # Intentionally contains the removed hunk to prevent patch aging -Patch1: poetry-core-1.0.2-devendor.patch + +# poetry is broken with packaging 21+ (https://github.com/python-poetry/poetry/issues/4264). +# We are temporarily disabling this patch so installed poetry works again. +#Patch1: poetry-core-1.0.2-devendor.patch BuildArch: noarch BuildRequires: python3-devel @@ -37,6 +53,15 @@ Summary: %{summary} # Previous versions of poetry included poetry-core in it Conflicts: python%{python3_version}dist(poetry) < 1.1 +# The bundled versions are taken from poetry/core/_vendor/vendor.txt +Provides: bundled(python3dist(attrs)) = 20.3 +Provides: bundled(python3dist(jsonschema)) = 3.2 +Provides: bundled(python3dist(lark-parser)) = 0.9 +Provides: bundled(python3dist(packaging)) = 20.9 +Provides: bundled(python3dist(pyparsing)) = 2.4.7 +Provides: bundled(python3dist(pyrsistent)) = 0.16.1 +Provides: bundled(python3dist(six)) = 1.15 +Provides: bundled(python3dist(tomlkit)) = 0.7 %description -n python3-poetry-core %_description @@ -44,6 +69,12 @@ Conflicts: python%{python3_version}dist(poetry) < 1.1 %prep %autosetup -p1 -n poetry-core-%{version} +# We sed out shebang from non-execeutable-script to fix rpmlint error. +# This can be removed once we again devendor python-poetry-core and +# the Patch1 is enabled again. +# Upstream PR: https://github.com/Julian/jsonschema/pull/833 +sed -i '1!b;/^#!/d' poetry/core/_vendor/jsonschema/benchmarks/issue232.py +sed -i '1!b;/^#!/d' poetry/core/_vendor/jsonschema/benchmarks/json_schema_test_suite.py %generate_buildrequires %pyproject_buildrequires -r @@ -51,7 +82,7 @@ Conflicts: python%{python3_version}dist(poetry) < 1.1 %build # we debundle the deps after we use the bundled deps in previous step to parse the deps 🤯 -rm -r poetry/core/_vendor +#rm -r poetry/core/_vendor %pyproject_wheel @@ -73,6 +104,9 @@ rm -r poetry/core/_vendor %changelog +* Thu Aug 19 2021 Tomas Hrnciar - 1.0.3-5 +- Bundle vendored libraries again, to fix poetry install + * Fri Jul 23 2021 Fedora Release Engineering - 1.0.3-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild