diff -Nru logilab-common-1.9.7/debian/changelog logilab-common-1.9.8/debian/changelog --- logilab-common-1.9.7/debian/changelog 2022-12-10 05:16:45.000000000 +0000 +++ logilab-common-1.9.8/debian/changelog 2023-01-22 05:43:33.000000000 +0000 @@ -1,3 +1,13 @@ +logilab-common (1.9.8-1) unstable; urgency=medium + + * New upstream release + * debian/copyright + - extend packaging copyright years + * debian/control + - bump Standards-Version to 4.6.2.0 (no changes needed) + + -- Sandro Tosi Sun, 22 Jan 2023 00:43:33 -0500 + logilab-common (1.9.7-1) unstable; urgency=medium * New upstream release diff -Nru logilab-common-1.9.7/debian/control logilab-common-1.9.8/debian/control --- logilab-common-1.9.7/debian/control 2022-12-10 05:16:45.000000000 +0000 +++ logilab-common-1.9.8/debian/control 2023-01-22 05:43:33.000000000 +0000 @@ -12,7 +12,7 @@ python3-sphinx , python3-typing-extensions , python3-tz , -Standards-Version: 4.6.1.0 +Standards-Version: 4.6.2.0 Homepage: https://www.logilab.org/project/logilab-common Vcs-Git: https://salsa.debian.org/python-team/packages/logilab-common.git Vcs-Browser: https://salsa.debian.org/python-team/packages/logilab-common diff -Nru logilab-common-1.9.7/debian/copyright logilab-common-1.9.8/debian/copyright --- logilab-common-1.9.7/debian/copyright 2022-12-10 05:16:45.000000000 +0000 +++ logilab-common-1.9.8/debian/copyright 2023-01-22 05:43:33.000000000 +0000 @@ -13,5 +13,5 @@ Version 2.1 may be found in '/usr/share/common-licenses/LGPL-2.1'. Files: debian/* -Copyright: Copyright (C) 2008-2022, Sandro Tosi +Copyright: Copyright (C) 2008-2023, Sandro Tosi License: LGPL-2.1 diff -Nru logilab-common-1.9.7/logilab/common/deprecation.py logilab-common-1.9.8/logilab/common/deprecation.py --- logilab-common-1.9.7/logilab/common/deprecation.py 2022-06-07 14:22:38.000000000 +0000 +++ logilab-common-1.9.8/logilab/common/deprecation.py 2023-01-04 22:32:31.000000000 +0000 @@ -34,6 +34,16 @@ import importlib_metadata +class FakeDistribution(importlib_metadata.Distribution): + "see https://github.com/python/importlib_metadata/blob/main/CHANGES.rst#v600" + + def locate_file(self): + pass + + def read_text(self): + pass + + def _unstack_all_deprecation_decorators(function): """ This is another super edge magic case which is needed because we uses @@ -172,7 +182,7 @@ # mypy fails to understand the result of .discover(): Cannot # instantiate abstract class 'Distribution' with abstract attributes # 'locate_file' and 'read_text' - for distribution in importlib_metadata.Distribution().discover(): # type: ignore + for distribution in FakeDistribution().discover(): # type: ignore # sometime distribution has a "name" attribute, sometime not if distribution.files and hasattr(distribution, "name"): for file in distribution.files: diff -Nru logilab-common-1.9.7/logilab/common/table.py logilab-common-1.9.8/logilab/common/table.py --- logilab-common-1.9.7/logilab/common/table.py 2022-06-07 14:22:38.000000000 +0000 +++ logilab-common-1.9.8/logilab/common/table.py 2023-01-04 22:32:31.000000000 +0000 @@ -516,7 +516,6 @@ """Defines a table's style""" def __init__(self, table: Table) -> None: - self._table = table self.size = dict([(col_name, "1*") for col_name in table.col_names]) # __row_column__ is a special key to define the first column which diff -Nru logilab-common-1.9.7/logilab/common/testlib.py logilab-common-1.9.8/logilab/common/testlib.py --- logilab-common-1.9.7/logilab/common/testlib.py 2022-06-07 14:22:38.000000000 +0000 +++ logilab-common-1.9.8/logilab/common/testlib.py 2023-01-04 22:32:31.000000000 +0000 @@ -114,7 +114,6 @@ @wraps(callable) def proxy(*args: Any, **kargs: Any) -> Any: - old_tmpdir = tempfile.gettempdir() new_tmpdir = tempfile.mkdtemp(prefix="temp-lgc-") tempfile.tempdir = new_tmpdir @@ -134,7 +133,6 @@ @wraps(callable) def proxy(*args, **kargs): - old_cwd = os.getcwd() os.chdir(tempfile.tempdir) try: diff -Nru logilab-common-1.9.7/logilab/common/ureports/__init__.py logilab-common-1.9.8/logilab/common/ureports/__init__.py --- logilab-common-1.9.7/logilab/common/ureports/__init__.py 2022-06-07 14:22:38.000000000 +0000 +++ logilab-common-1.9.8/logilab/common/ureports/__init__.py 2023-01-04 22:32:31.000000000 +0000 @@ -163,6 +163,7 @@ return an iterator on strings (one for each child element) """ + # use cells ! def write(data: str) -> None: try: diff -Nru logilab-common-1.9.7/logilab/common/ureports/nodes.py logilab-common-1.9.8/logilab/common/ureports/nodes.py --- logilab-common-1.9.7/logilab/common/ureports/nodes.py 2022-06-07 14:22:38.000000000 +0000 +++ logilab-common-1.9.8/logilab/common/ureports/nodes.py 2023-01-04 22:32:31.000000000 +0000 @@ -63,7 +63,6 @@ ] = (), **kwargs: Any, ) -> None: - super(BaseLayout, self).__init__(**kwargs) for child in children: diff -Nru logilab-common-1.9.7/logilab_common.egg-info/PKG-INFO logilab-common-1.9.8/logilab_common.egg-info/PKG-INFO --- logilab-common-1.9.7/logilab_common.egg-info/PKG-INFO 2022-06-07 14:22:57.000000000 +0000 +++ logilab-common-1.9.8/logilab_common.egg-info/PKG-INFO 2023-01-04 22:32:53.000000000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: logilab-common -Version: 1.9.7 +Version: 1.9.8 Summary: collection of low-level Python packages and modules used by Logilab projects Home-page: http://www.logilab.org/project/logilab-common Author: Logilab diff -Nru logilab-common-1.9.7/logilab_common.egg-info/requires.txt logilab-common-1.9.8/logilab_common.egg-info/requires.txt --- logilab-common-1.9.7/logilab_common.egg-info/requires.txt 2022-06-07 14:22:58.000000000 +0000 +++ logilab-common-1.9.8/logilab_common.egg-info/requires.txt 2023-01-04 22:32:53.000000000 +0000 @@ -1,3 +1,4 @@ setuptools mypy-extensions typing_extensions +importlib_metadata<7,>=6 diff -Nru logilab-common-1.9.7/PKG-INFO logilab-common-1.9.8/PKG-INFO --- logilab-common-1.9.7/PKG-INFO 2022-06-07 14:22:58.951329500 +0000 +++ logilab-common-1.9.8/PKG-INFO 2023-01-04 22:32:54.126615500 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: logilab-common -Version: 1.9.7 +Version: 1.9.8 Summary: collection of low-level Python packages and modules used by Logilab projects Home-page: http://www.logilab.org/project/logilab-common Author: Logilab diff -Nru logilab-common-1.9.7/__pkginfo__.py logilab-common-1.9.8/__pkginfo__.py --- logilab-common-1.9.7/__pkginfo__.py 2022-06-07 14:22:37.000000000 +0000 +++ logilab-common-1.9.8/__pkginfo__.py 2023-01-04 22:32:31.000000000 +0000 @@ -21,7 +21,6 @@ __docformat__ = "restructuredtext en" import os -import sys from os.path import join distname = "logilab-common" @@ -29,7 +28,7 @@ subpackage_of = "logilab" subpackage_master = True -numversion = (1, 9, 7) +numversion = (1, 9, 8) version = ".".join([str(num) for num in numversion]) license = "LGPL" # 2.1 or later @@ -47,6 +46,7 @@ "setuptools": None, "mypy-extensions": None, "typing_extensions": None, + "importlib_metadata": ">=6,<7", } tests_require = [ "pytz", @@ -56,9 +56,6 @@ if os.name == "nt": __depends__["colorama"] = None -if sys.version_info < (3, 8): - __depends__["importlib_metadata"] = None - classifiers = [ "Topic :: Utilities", "Programming Language :: Python", diff -Nru logilab-common-1.9.7/test/test_deprecation.py logilab-common-1.9.8/test/test_deprecation.py --- logilab-common-1.9.7/test/test_deprecation.py 2022-06-07 14:22:38.000000000 +0000 +++ logilab-common-1.9.8/test/test_deprecation.py 2023-01-04 22:32:31.000000000 +0000 @@ -31,7 +31,6 @@ class RawInputTC(TestCase): - # XXX with 2.6 we could test warnings # http://docs.python.org/library/warnings.html#testing-warnings # instead we just make sure it does not crash