Accepting request 1056694 from devel:languages:python

- update to 4.6:
  * Catch exceptions in ``formatExceptionOnly``.
  Getting an exception when reporting about a different exception is not helpful.
  On Python 3.11 this is needed for some HTTPErrors.
  * Add official support for Python 3.11.
  * Add official support for Python 3.9 and 3.10.
  * Undo dropping support for Python 3.5.
  * Drop support for running the tests using ``python setup.py test``.
- drop zope.exceptions-pr19+pr21-py310.patch (upstream)

OBS-URL: https://build.opensuse.org/request/show/1056694
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-zope.exceptions?expand=0&rev=13
This commit is contained in:
Dominique Leuenberger 2023-01-10 13:58:52 +00:00 committed by Git OBS Bridge
commit dbb596c455
5 changed files with 20 additions and 36 deletions

View File

@ -1,3 +1,16 @@
-------------------------------------------------------------------
Fri Jan 6 12:42:36 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 4.6:
* Catch exceptions in ``formatExceptionOnly``.
Getting an exception when reporting about a different exception is not helpful.
On Python 3.11 this is needed for some HTTPErrors.
* Add official support for Python 3.11.
* Add official support for Python 3.9 and 3.10.
* Undo dropping support for Python 3.5.
* Drop support for running the tests using ``python setup.py test``.
- drop zope.exceptions-pr19+pr21-py310.patch (upstream)
-------------------------------------------------------------------
Sun Dec 19 15:29:01 UTC 2021 - Ben Greiner <code@bnavigator.de>

View File

@ -1,7 +1,7 @@
#
# spec file
#
# Copyright (c) 2021 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
@ -26,27 +26,24 @@
%bcond_with test
%endif
Name: python-zope.exceptions%{psuffix}
Version: 4.4
Version: 4.6
Release: 0
Summary: Zope Exceptions
License: ZPL-2.1
Group: Development/Languages/Python
URL: http://cheeseshop.python.org/pypi/zope.exceptions
URL: https://cheeseshop.python.org/pypi/zope.exceptions
Source: https://files.pythonhosted.org/packages/source/z/zope.exceptions/zope.exceptions-%{version}.tar.gz
# PATCH-FIX-UPSTREAM zope.exceptions-pr19+pr21-py310.patch -- gh#zopefoundation/zope.exceptions#21
Patch0: zope.exceptions-pr19+pr21-py310.patch
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-zope.interface
Obsoletes: %{name}-doc
BuildArch: noarch
%if %{with test}
BuildRequires: %{python_module zope.exceptions}
BuildRequires: %{python_module zope.interface}
BuildRequires: %{python_module zope.testrunner}
%endif
BuildArch: noarch
%python_subpackages
%description

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0d72886b1bb8af4c346a117a540f28ab122577f5e3a105a261be72cd15776fda
size 28243

BIN
zope.exceptions-4.6.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,26 +0,0 @@
From 71be9d0724f087c99857edeef514d0b99e429cc9 Mon Sep 17 00:00:00 2001
From: Zamarin Arthur <arthurzam@gmail.com>
Date: Mon, 31 May 2021 12:14:30 +0300
Subject: [PATCH 1/2] Adapt to python 3.10 SyntaxError messages
Signed-off-by: Zamarin Arthur <arthurzam@gmail.com>
---
src/zope/exceptions/tests/test_exceptionformatter.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: zope.exceptions-4.4/src/zope/exceptions/tests/test_exceptionformatter.py
===================================================================
--- zope.exceptions-4.4.orig/src/zope/exceptions/tests/test_exceptionformatter.py
+++ zope.exceptions-4.4/src/zope/exceptions/tests/test_exceptionformatter.py
@@ -666,9 +666,8 @@ class Test_format_exception(unittest.Tes
s = self._callFUT(False)
lines = s.splitlines()[-3:]
self.assertEqual(lines[0], ' syntax error')
- # PyPy has a shorter prefix
- self.assertTrue(lines[1].endswith(' ^'))
- self.assertEqual(lines[2], 'SyntaxError: invalid syntax')
+ self.assertIn(' ^', lines[1])
+ self.assertTrue(lines[2].startswith('SyntaxError: invalid syntax'), lines[2])
def test_traceback_info_non_ascii(self):
__traceback_info__ = u"Have a Snowman: \u2603"