diff --git a/ipywidgets-pr2655-collectionsabc.patch b/ipywidgets-pr2655-collectionsabc.patch new file mode 100644 index 0000000..a754ad4 --- /dev/null +++ b/ipywidgets-pr2655-collectionsabc.patch @@ -0,0 +1,37 @@ +From f9a13dbb3b8f1ffefef483bdb4c14f04f7743ff1 Mon Sep 17 00:00:00 2001 +From: Jason Grout +Date: Tue, 31 Dec 2019 12:57:52 -0800 +Subject: [PATCH] Fix more python 3 deprecations + +--- + ipywidgets/widgets/interaction.py | 2 +- + ipywidgets/widgets/tests/test_interaction.py | 3 ++- + 2 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/ipywidgets/widgets/interaction.py b/ipywidgets/widgets/interaction.py +index 3dd7272047..6e3b9fc955 100644 +--- a/ipywidgets/widgets/interaction.py ++++ b/ipywidgets/widgets/interaction.py +@@ -246,7 +246,7 @@ def update(self, *args): + except Exception as e: + ip = get_ipython() + if ip is None: +- self.log.warn("Exception in interact callback: %s", e, exc_info=True) ++ self.log.warning("Exception in interact callback: %s", e, exc_info=True) + else: + ip.showtraceback() + finally: +diff --git a/ipywidgets/widgets/tests/test_interaction.py b/ipywidgets/widgets/tests/test_interaction.py +index 1ee946744e..c792c5377a 100644 +--- a/ipywidgets/widgets/tests/test_interaction.py ++++ b/ipywidgets/widgets/tests/test_interaction.py +@@ -249,7 +249,8 @@ def test_iterable_tuple(): + check_widgets(c, lis=d) + + def test_mapping(): +- from collections import Mapping, OrderedDict ++ from collections.abc import Mapping ++ from collections import OrderedDict + class TestMapping(Mapping): + def __init__(self, values): + self.values = values diff --git a/python-ipywidgets.changes b/python-ipywidgets.changes index fd32901..d1f5568 100644 --- a/python-ipywidgets.changes +++ b/python-ipywidgets.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jan 6 13:13:37 UTC 2022 - Ben Greiner + +- Add ipywidgets-pr2655-collectionsabc.patch for python310 support + ------------------------------------------------------------------- Sun Oct 17 20:53:43 UTC 2021 - Ben Greiner diff --git a/python-ipywidgets.spec b/python-ipywidgets.spec index 101c734..5809b93 100644 --- a/python-ipywidgets.spec +++ b/python-ipywidgets.spec @@ -1,7 +1,7 @@ # # spec file for package python-ipywidgets # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -26,6 +26,8 @@ License: BSD-3-Clause Group: Development/Languages/Python URL: https://github.com/jupyter-widgets/ipywidgets Source0: https://files.pythonhosted.org/packages/source/i/ipywidgets/ipywidgets-%{version}.tar.gz +# PATCH-FIX-UPSTREAM ipywidgets-pr2655-collectionsabc.patch -- gh#jupyter-widgets/ipywidgets#2655 +Patch0: https://github.com/jupyter-widgets/ipywidgets/commit/f9a13dbb3b8f1ffefef483bdb4c14f04f7743ff1.patch#/ipywidgets-pr2655-collectionsabc.patch BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros @@ -59,7 +61,7 @@ Provides: jupyter-ipywidgets = %{version} Interactive HTML widgets for Jupyter notebooks and the IPython kernel. %prep -%setup -q -n ipywidgets-%{version} +%autosetup -p1 -n ipywidgets-%{version} %build %python_build