From 0e9565f831da2377622c79bfd6e5be37f7baaa7c Mon Sep 17 00:00:00 2001 From: Fabrice Fontaine Date: Tue, 22 Feb 2022 18:49:57 +0100 Subject: [PATCH] package/python-pycli: drop package Even with the two upstream patches added in commit b2e6e376a2d7551ccf146855ec4e99a65c35bd16, python-pycli still raises the following build failure since bump of python3 to version 3.10.1 in commit 25b1fc2898d68ddf2674b14c738045875fc5a2dc due to the new "Multiple Exception types without parentheses" exception (https://docs.python.org/3/whatsnew/3.10.html): error: File "/usr/lib/python3.10/site-packages/cli/test.py", line 142 except raises, e: ^^^^^^^^^ SyntaxError: multiple exception types must be parenthesized So drop the package as the last release was made 10 years ago. Fixes: - http://autobuild.buildroot.org/results/6112e1830ce608abcea4a26b659c10e5ff09a66a Signed-off-by: Fabrice Fontaine Signed-off-by: Arnout Vandecappelle (Essensium/Mind) --- Config.in.legacy | 7 ++++ DEVELOPERS | 1 - package/Config.in | 1 - ...aise-exceptions-in-wrapped-functions.patch | 26 ------------ ...pt-statement-changed-slightly-in-2-6.patch | 41 ------------------- package/python-pycli/Config.in | 7 ---- package/python-pycli/python-pycli.hash | 5 --- package/python-pycli/python-pycli.mk | 14 ------- 8 files changed, 7 insertions(+), 95 deletions(-) delete mode 100644 package/python-pycli/0001-Fix-problem-with-re-raise-exceptions-in-wrapped-functions.patch delete mode 100644 package/python-pycli/0002-except-statement-changed-slightly-in-2-6.patch delete mode 100644 package/python-pycli/Config.in delete mode 100644 package/python-pycli/python-pycli.hash delete mode 100644 package/python-pycli/python-pycli.mk diff --git a/Config.in.legacy b/Config.in.legacy index b90b9dbcbc..3b066bbf72 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -158,6 +158,13 @@ config BR2_PACKAGE_WESTON_FBDEV help fbdev compositor was deprecated in weston 10.0.0. +config BR2_PACKAGE_PYTHON_PYCLI + bool "python-pycli removed" + select BR2_LEGACY + help + Package was removed because it is not compatible with python + 3.10 and is not maintained anymore (no release since 2012). + config BR2_PACKAGE_LINUX_TOOLS_BPFTOOL bool "bpftool was moved" select BR2_LEGACY diff --git a/DEVELOPERS b/DEVELOPERS index b7a7c8771c..b5183711b5 100644 --- a/DEVELOPERS +++ b/DEVELOPERS @@ -1061,7 +1061,6 @@ N: Geoff Levand F: package/flannel/ N: Geoffrey Ragot -F: package/python-pycli/ F: package/python-pyyaml/ N: Gerome Burlats diff --git a/package/Config.in b/package/Config.in index 8d2d550a64..517e66cce7 100644 --- a/package/Config.in +++ b/package/Config.in @@ -1144,7 +1144,6 @@ menu "External python modules" source "package/python-pybind/Config.in" source "package/python-pycairo/Config.in" source "package/python-pycares/Config.in" - source "package/python-pycli/Config.in" source "package/python-pycparser/Config.in" source "package/python-pycryptodomex/Config.in" source "package/python-pycups/Config.in" diff --git a/package/python-pycli/0001-Fix-problem-with-re-raise-exceptions-in-wrapped-functions.patch b/package/python-pycli/0001-Fix-problem-with-re-raise-exceptions-in-wrapped-functions.patch deleted file mode 100644 index 7ac9d7af9f..0000000000 --- a/package/python-pycli/0001-Fix-problem-with-re-raise-exceptions-in-wrapped-functions.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 57c563f8b47a56feefc0a8bcbef05f4b54280549 Mon Sep 17 00:00:00 2001 -From: mmbutter -Date: Tue, 9 Jun 2020 11:50:41 -0500 -Subject: [PATCH] Fix problem with re-raise exceptions in wrapped functions. - -[Retrieved from: -https://github.com/whilp/cli/commit/57c563f8b47a56feefc0a8bcbef05f4b54280549] -Signed-off-by: Fabrice Fontaine ---- - lib/cli/app.py | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/lib/cli/app.py b/lib/cli/app.py -index 7b6db52..f487ab4 100644 ---- a/lib/cli/app.py -+++ b/lib/cli/app.py -@@ -240,6 +240,9 @@ def run(self): - try: - returned = self.main(*args) - except Exception, e: -+ elif isinstance(e, self.reraise): -+ # raising the last exception preserves traceback -+ raise - returned = e - - return self.post_run(returned) diff --git a/package/python-pycli/0002-except-statement-changed-slightly-in-2-6.patch b/package/python-pycli/0002-except-statement-changed-slightly-in-2-6.patch deleted file mode 100644 index 75869d6d23..0000000000 --- a/package/python-pycli/0002-except-statement-changed-slightly-in-2-6.patch +++ /dev/null @@ -1,41 +0,0 @@ -From 2af95cff5609142ec14efdf13b394f9b0121ab2e Mon Sep 17 00:00:00 2001 -From: mmbutter -Date: Thu, 11 Jun 2020 15:50:03 -0500 -Subject: [PATCH] except statement changed slightly in 2.6. This could cause - problems in newer versions. Updated to the new format. - -[Retrieved from: -https://github.com/whilp/cli/commit/2af95cff5609142ec14efdf13b394f9b0121ab2e] -Signed-off-by: Fabrice Fontaine ---- - lib/cli/app.py | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) - -diff --git a/lib/cli/app.py b/lib/cli/app.py -index f487ab4..45256b8 100644 ---- a/lib/cli/app.py -+++ b/lib/cli/app.py -@@ -239,10 +239,10 @@ def run(self): - args = () - try: - returned = self.main(*args) -- except Exception, e: -- elif isinstance(e, self.reraise): -- # raising the last exception preserves traceback -- raise -+ except self.reraise: -+ # raising the last exception preserves traceback -+ raise -+ except Exception as e: - returned = e - - return self.post_run(returned) -@@ -420,7 +420,7 @@ def pre_run(self): - """ - try: - ns = self.argparser.parse_args() -- except SystemExit, e: -+ except SystemExit as e: - if self.exit_after_main: - raise - else: diff --git a/package/python-pycli/Config.in b/package/python-pycli/Config.in deleted file mode 100644 index e1ce3b99a6..0000000000 --- a/package/python-pycli/Config.in +++ /dev/null @@ -1,7 +0,0 @@ -config BR2_PACKAGE_PYTHON_PYCLI - bool "python-pycli" - help - The cli package is a framework for making simple, correct - command line applications in Python. - - https://pythonhosted.org/pyCLI/ diff --git a/package/python-pycli/python-pycli.hash b/package/python-pycli/python-pycli.hash deleted file mode 100644 index f0890e83a9..0000000000 --- a/package/python-pycli/python-pycli.hash +++ /dev/null @@ -1,5 +0,0 @@ -# md5 from https://pypi.python.org/pypi/pycli/json -md5 89c487e7c8068ce05d63394d2ae7ebad pyCLI-2.0.3.tar.gz -# Locally computed -sha256 bc53e6c5db031ae1c05d131641f153d22a201c5e82cc8c9324a945752efbb622 pyCLI-2.0.3.tar.gz -sha256 591490b2ef462a4ad2be1aae5dd47738cb17e191c82d3ba38c3ae906d288e6ba lib/cli/__init__.py diff --git a/package/python-pycli/python-pycli.mk b/package/python-pycli/python-pycli.mk deleted file mode 100644 index 7aff1c6200..0000000000 --- a/package/python-pycli/python-pycli.mk +++ /dev/null @@ -1,14 +0,0 @@ -################################################################################ -# -# python-pycli -# -################################################################################ - -PYTHON_PYCLI_VERSION = 2.0.3 -PYTHON_PYCLI_SOURCE = pyCLI-$(PYTHON_PYCLI_VERSION).tar.gz -PYTHON_PYCLI_SITE = https://pypi.python.org/packages/95/fc/b2d86a5fbdac4072bcf70b01674b612e1a13026f54962c878fe3eca36fd1 -PYTHON_PYCLI_LICENSE = ISC-like -PYTHON_PYCLI_LICENSE_FILES = lib/cli/__init__.py -PYTHON_PYCLI_SETUP_TYPE = setuptools - -$(eval $(python-package))