From de5b70f392a31a8cf7817194da7fa8c7fdbd3a8450044ddd4d13bd2b3caabbb8 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Tue, 9 May 2023 06:41:52 +0000 Subject: [PATCH] Accepting request 1085583 from home:bnavigator:branches:devel:languages:python - Strip down build requirement to poetry-core * Add colorclass-pr2-poetry-core.patch * gh#matthewdeanmartin/colorclass#2 OBS-URL: https://build.opensuse.org/request/show/1085583 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-colorclass?expand=0&rev=7 --- colorclass-pr2-poetry-core.patch | 26 ++++++++++++++++++++++++++ python-colorclass.changes | 7 +++++++ python-colorclass.spec | 9 +++++---- 3 files changed, 38 insertions(+), 4 deletions(-) create mode 100644 colorclass-pr2-poetry-core.patch diff --git a/colorclass-pr2-poetry-core.patch b/colorclass-pr2-poetry-core.patch new file mode 100644 index 0000000..0581d31 --- /dev/null +++ b/colorclass-pr2-poetry-core.patch @@ -0,0 +1,26 @@ +From c3f8ad8419e7ec0886a48708da705fe1fb3693a7 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= +Date: Wed, 26 Jan 2022 22:14:08 +0100 +Subject: [PATCH] switch to poetry-core build backend + +Switch the build backend from poetry to poetry-core. This is a lighter +version that's more suitable for PEP 517 builds. The resulting +artifacts are the same but poetry-core has less dependencies (as it does +not pull the whole package manager in) and therefore wheel builds +are much faster. +--- + pyproject.toml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/pyproject.toml b/pyproject.toml +index 65eaec9..65a8767 100644 +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -62,5 +62,5 @@ python = ">=2.6 || >=3.0" + pytest = "==6.0.1" + + [build-system] +-requires = ["poetry>=0.12"] +-build-backend = "poetry.masonry.api" ++requires = ["poetry-core>=0.12"] ++build-backend = "poetry.core.masonry.api" diff --git a/python-colorclass.changes b/python-colorclass.changes index 09c304e..1b04b83 100644 --- a/python-colorclass.changes +++ b/python-colorclass.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Mon May 8 21:19:05 UTC 2023 - Ben Greiner + +- Strip down build requirement to poetry-core + * Add colorclass-pr2-poetry-core.patch + * gh#matthewdeanmartin/colorclass#2 + ------------------------------------------------------------------- Thu Jan 13 22:29:37 UTC 2022 - Ben Greiner diff --git a/python-colorclass.spec b/python-colorclass.spec index decf218..5d20b4a 100644 --- a/python-colorclass.spec +++ b/python-colorclass.spec @@ -1,7 +1,7 @@ # # spec file for package python-colorclass # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,7 +16,6 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-colorclass Version: 2.2.2 Release: 0 @@ -25,8 +24,10 @@ License: MIT Group: Development/Languages/Python URL: https://github.com/matthewdeanmartin/colorclass/ Source: https://github.com/matthewdeanmartin/colorclass/archive/refs/tags/v%{version}.tar.gz#/colorclass-%{version}-gh.tar.gz +# PATCH-FIX-UPSTREAM colorclass-pr2-poetry-core.patch gh#matthewdeanmartin/colorclass#2 +Patch0: colorclass-pr2-poetry-core.patch BuildRequires: %{python_module pip} -BuildRequires: %{python_module poetry} +BuildRequires: %{python_module poetry-core} BuildRequires: %{python_module pytest} BuildRequires: fdupes BuildRequires: python-rpm-macros @@ -42,7 +43,7 @@ In Python 2.x, this library subclasses `unicode`, while on Python 3.x, it subclasses `str`. %prep -%setup -q -n colorclass-%{version} +%autosetup -p1 -n colorclass-%{version} %build %pyproject_wheel