From e433759168cfb3b675c4f63e760599bf4ab82cd7a4f2642dbdab3f4bf3dfab12 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Fri, 2 Dec 2022 10:48:41 +0000 Subject: [PATCH 1/3] Accepting request 1039279 from home:ojkastl_buildservice:Branch_devel_languages_python update to 1.0.4 OBS-URL: https://build.opensuse.org/request/show/1039279 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-exceptiongroup?expand=0&rev=5 --- _service | 4 ++++ exceptiongroup-1.0.0rc9-gh.tar.gz | 3 --- exceptiongroup-1.0.4-gh.tar.gz | 3 +++ python-exceptiongroup.changes | 16 ++++++++++++++++ python-exceptiongroup.spec | 12 +++++------- 5 files changed, 28 insertions(+), 10 deletions(-) create mode 100644 _service delete mode 100644 exceptiongroup-1.0.0rc9-gh.tar.gz create mode 100644 exceptiongroup-1.0.4-gh.tar.gz diff --git a/_service b/_service new file mode 100644 index 0000000..1bd86b8 --- /dev/null +++ b/_service @@ -0,0 +1,4 @@ + + + + diff --git a/exceptiongroup-1.0.0rc9-gh.tar.gz b/exceptiongroup-1.0.0rc9-gh.tar.gz deleted file mode 100644 index 8c9d4c4..0000000 --- a/exceptiongroup-1.0.0rc9-gh.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ddd6f144d7c33f54b9bb6009be2b514416e7c13eb7853d1241d2d82e31212dfd -size 19109 diff --git a/exceptiongroup-1.0.4-gh.tar.gz b/exceptiongroup-1.0.4-gh.tar.gz new file mode 100644 index 0000000..9a3f552 --- /dev/null +++ b/exceptiongroup-1.0.4-gh.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:69e8a2ddd1b03175ca2c43f474bb1e7eb5074afadf73e63e9c905cdee1a82a6b +size 22529 diff --git a/python-exceptiongroup.changes b/python-exceptiongroup.changes index df8d605..7adff02 100644 --- a/python-exceptiongroup.changes +++ b/python-exceptiongroup.changes @@ -1,3 +1,19 @@ +------------------------------------------------------------------- +Thu Dec 1 09:42:08 UTC 2022 - Johannes Kastl + +- update to 1.0.4: + * Fixed regression introduced in v1.0.3 where the code computing the suggestions would assume that both the obj attribute of AttributeError is always available, even though this is only true from Python 3.10 onwards (#43; PR by Carl Friedrich Bolz-Tereick) +- update to 1.0.3: + * Fixed monkey patching breaking suggestions (on a NameError or AttributeError) on Python 3.10 (#41; PR by Carl Friedrich Bolz-Tereick) +- update to 1.0.2: + * Updated type annotations to match the ones in typeshed +- update to 1.0.1: + * Fixed formatted traceback missing exceptions beyond 2 nesting levels of __context__ or __cause__ +- update to 1.0.0: + * Fixed AttributeError: 'PatchedTracebackException' object has no attribute '__cause__' on Python 3.10 (only) when a traceback is printed from an exception where an exception group is set as the cause (#33) + * Fixed a loop in exception groups being rendered incorrectly (#35) + * Fixed the patched formatting functions (format_exception()``etc.) not passing the ``compact=True flag on Python 3.10 like the original functions do + ------------------------------------------------------------------- Wed Oct 26 19:53:01 UTC 2022 - Matej Cepl diff --git a/python-exceptiongroup.spec b/python-exceptiongroup.spec index e0b6ea9..50acc04 100644 --- a/python-exceptiongroup.spec +++ b/python-exceptiongroup.spec @@ -16,14 +16,13 @@ # -%define pyversion 1.0.0rc9 Name: python-exceptiongroup -Version: 1.0.0~rc9 +Version: 1.0.4 Release: 0 Summary: Backport of PEP 654 (exception groups) License: MIT AND Python-2.0 URL: https://github.com/agronholm/exceptiongroup -Source: https://github.com/agronholm/exceptiongroup/archive/refs/tags/%{pyversion}.tar.gz#/exceptiongroup-%{pyversion}-gh.tar.gz +Source: https://github.com/agronholm/exceptiongroup/archive/refs/tags/%{version}.tar.gz#/exceptiongroup-%{version}-gh.tar.gz BuildRequires: %{python_module base >= 3.7} BuildRequires: %{python_module flit-scm} BuildRequires: %{python_module pip} @@ -61,10 +60,10 @@ exception group classes are used instead, ``TracebackException`` is not monkey p and the exception hook won't be installed. %prep -%setup -q -n exceptiongroup-%{pyversion} +%setup -q -n exceptiongroup-%{version} %build -export SETUPTOOLS_SCM_PRETEND_VERSION=%{pyversion} +export SETUPTOOLS_SCM_PRETEND_VERSION=%{version} %pyproject_wheel %install @@ -77,7 +76,6 @@ export SETUPTOOLS_SCM_PRETEND_VERSION=%{pyversion} %files %{python_files} %doc README.rst %license LICENSE -%{python_sitelib}/exceptiongroup -%{python_sitelib}/exceptiongroup-%{pyversion}*-info +%{python_sitelib}/exceptiongroup* %changelog From ce7d00b0038c592527626544439042c85430e63fa406c990d8a69c752f7ae498 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Mon, 19 Dec 2022 10:09:00 +0000 Subject: [PATCH 2/3] - split tests into multibuild to solve cycle with pytest OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-exceptiongroup?expand=0&rev=6 --- _multibuild | 3 +++ python-exceptiongroup.changes | 5 +++++ python-exceptiongroup.spec | 18 ++++++++++++++++-- 3 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 _multibuild diff --git a/_multibuild b/_multibuild new file mode 100644 index 0000000..fcc7b97 --- /dev/null +++ b/_multibuild @@ -0,0 +1,3 @@ + + test + diff --git a/python-exceptiongroup.changes b/python-exceptiongroup.changes index 7adff02..d0802cc 100644 --- a/python-exceptiongroup.changes +++ b/python-exceptiongroup.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Dec 19 10:08:40 UTC 2022 - Dirk Müller + +- split tests into multibuild to solve cycle with pytest + ------------------------------------------------------------------- Thu Dec 1 09:42:08 UTC 2022 - Johannes Kastl diff --git a/python-exceptiongroup.spec b/python-exceptiongroup.spec index 50acc04..75d883f 100644 --- a/python-exceptiongroup.spec +++ b/python-exceptiongroup.spec @@ -1,5 +1,5 @@ # -# spec file for package python-exceptiongroup +# spec file # # Copyright (c) 2022 SUSE LLC # @@ -16,7 +16,17 @@ # -Name: python-exceptiongroup +# This is not only because of dependency of testsuite, but mostly +# because of cyclical dependencies between exceptiongroup and pytest. +%global flavor @BUILD_FLAVOR@%{nil} +%if "%{flavor}" == "test" +%bcond_without test +%define psuffix -test +%else +%bcond_with test +%define psuffix %{nil} +%endif +Name: python-exceptiongroup%{psuffix} Version: 1.0.4 Release: 0 Summary: Backport of PEP 654 (exception groups) @@ -26,7 +36,9 @@ Source: https://github.com/agronholm/exceptiongroup/archive/refs/tags/%{ BuildRequires: %{python_module base >= 3.7} BuildRequires: %{python_module flit-scm} BuildRequires: %{python_module pip} +%if %{with test} BuildRequires: %{python_module pytest} +%endif BuildRequires: fdupes BuildRequires: python-rpm-macros BuildArch: noarch @@ -70,8 +82,10 @@ export SETUPTOOLS_SCM_PRETEND_VERSION=%{version} %pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} +%if %{with test} %check %pytest +%endif %files %{python_files} %doc README.rst From f487522a7e68ca4146b9000c415b58d69ccce9432acf137d08d9b118f1bce241 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Fri, 23 Dec 2022 16:15:56 +0000 Subject: [PATCH 3/3] Accepting request 1045038 from home:bnavigator:branches:devel:languages:python - Update to 1.1.0 * Backported upstream fix for gh-99553 (custom subclasses of BaseExceptionGroup that also inherit from Exception should not be able to wrap base exceptions) * Moved all initialization code to __new__() (thus matching Python 3.11 behavior) - Fix multibuild OBS-URL: https://build.opensuse.org/request/show/1045038 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-exceptiongroup?expand=0&rev=7 --- _service | 4 ---- exceptiongroup-1.0.4-gh.tar.gz | 3 --- exceptiongroup-1.1.0-gh.tar.gz | 3 +++ python-exceptiongroup.changes | 11 +++++++++++ python-exceptiongroup.spec | 11 +++++++++-- 5 files changed, 23 insertions(+), 9 deletions(-) delete mode 100644 _service delete mode 100644 exceptiongroup-1.0.4-gh.tar.gz create mode 100644 exceptiongroup-1.1.0-gh.tar.gz diff --git a/_service b/_service deleted file mode 100644 index 1bd86b8..0000000 --- a/_service +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/exceptiongroup-1.0.4-gh.tar.gz b/exceptiongroup-1.0.4-gh.tar.gz deleted file mode 100644 index 9a3f552..0000000 --- a/exceptiongroup-1.0.4-gh.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:69e8a2ddd1b03175ca2c43f474bb1e7eb5074afadf73e63e9c905cdee1a82a6b -size 22529 diff --git a/exceptiongroup-1.1.0-gh.tar.gz b/exceptiongroup-1.1.0-gh.tar.gz new file mode 100644 index 0000000..326ca76 --- /dev/null +++ b/exceptiongroup-1.1.0-gh.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9036aa671fa6fcd0f40ee80f9f373697c3501fb66ac0dbec3bce50baeda81e1d +size 22724 diff --git a/python-exceptiongroup.changes b/python-exceptiongroup.changes index d0802cc..3ec7e84 100644 --- a/python-exceptiongroup.changes +++ b/python-exceptiongroup.changes @@ -1,3 +1,14 @@ +------------------------------------------------------------------- +Fri Dec 23 15:24:56 UTC 2022 - Ben Greiner + +- Update to 1.1.0 + * Backported upstream fix for gh-99553 (custom subclasses of + BaseExceptionGroup that also inherit from Exception should not + be able to wrap base exceptions) + * Moved all initialization code to __new__() (thus matching + Python 3.11 behavior) +- Fix multibuild + ------------------------------------------------------------------- Mon Dec 19 10:08:40 UTC 2022 - Dirk Müller diff --git a/python-exceptiongroup.spec b/python-exceptiongroup.spec index 75d883f..fa386c8 100644 --- a/python-exceptiongroup.spec +++ b/python-exceptiongroup.spec @@ -26,8 +26,9 @@ %bcond_with test %define psuffix %{nil} %endif + Name: python-exceptiongroup%{psuffix} -Version: 1.0.4 +Version: 1.1.0 Release: 0 Summary: Backport of PEP 654 (exception groups) License: MIT AND Python-2.0 @@ -37,6 +38,7 @@ BuildRequires: %{python_module base >= 3.7} BuildRequires: %{python_module flit-scm} BuildRequires: %{python_module pip} %if %{with test} +BuildRequires: %{python_module exceptiongroup = %{version}} BuildRequires: %{python_module pytest} %endif BuildRequires: fdupes @@ -74,6 +76,7 @@ and the exception hook won't be installed. %prep %setup -q -n exceptiongroup-%{version} +%if !%{with test} %build export SETUPTOOLS_SCM_PRETEND_VERSION=%{version} %pyproject_wheel @@ -81,15 +84,19 @@ export SETUPTOOLS_SCM_PRETEND_VERSION=%{version} %install %pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} +%endif %if %{with test} %check %pytest %endif +%if !%{with test} %files %{python_files} %doc README.rst %license LICENSE -%{python_sitelib}/exceptiongroup* +%{python_sitelib}/exceptiongroup +%{python_sitelib}/exceptiongroup-%{version}.dist-info +%endif %changelog