Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-pathtools for 
openSUSE:Factory checked in at 2023-08-18 19:27:48
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pathtools (Old)
 and      /work/SRC/openSUSE:Factory/.python-pathtools.new.1766 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-pathtools"

Fri Aug 18 19:27:48 2023 rev:12 rq:1104099 version:0.1.2

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pathtools/python-pathtools.changes        
2023-06-12 15:26:35.663102742 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-pathtools.new.1766/python-pathtools.changes  
    2023-08-18 19:27:58.399274387 +0200
@@ -1,0 +2,7 @@
+Wed Aug 16 05:17:49 UTC 2023 - Steve Kowalik <[email protected]>
+
+- Add patch stop-using-imp.patch:
+  * Stop using imp module, switch to importlib.*
+- Use pyproject macros.
+
+-------------------------------------------------------------------

New:
----
  stop-using-imp.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-pathtools.spec ++++++
--- /var/tmp/diff_new_pack.x8S0xa/_old  2023-08-18 19:27:59.639276610 +0200
+++ /var/tmp/diff_new_pack.x8S0xa/_new  2023-08-18 19:27:59.647276625 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package python-pathtools
 #
-# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
+# 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
@@ -24,7 +24,11 @@
 License:        MIT
 URL:            https://github.com/gorakhargosh/pathtools
 Source:         
https://files.pythonhosted.org/packages/source/p/pathtools/pathtools-%{version}.tar.gz
+# PATCH-FIX-OPENSUSE Stop using imp module
+Patch0:         stop-using-imp.patch
+BuildRequires:  %{python_module pip}
 BuildRequires:  %{python_module setuptools}
+BuildRequires:  %{python_module wheel}
 BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
 BuildRequires:  python3-Sphinx
@@ -35,22 +39,22 @@
 Pattern matching and various utilities for file systems paths.
 
 %prep
-%setup -q -n pathtools-%{version}
+%autosetup -p1 -n pathtools-%{version}
 sed -i "1d" pathtools/path.py pathtools/patterns.py
 sed -i "s/^html_theme.*/#html_theme/" docs/source/conf.py
 
 %build
-%python_build
+%pyproject_wheel
 cd docs && make html && rm -r build/html/.buildinfo # Build HTML docs
 
 %install
-%python_install
+%pyproject_install
 %python_expand %fdupes %{buildroot}%{$python_sitelib}
 
 %files %{python_files}
 %license LICENSE
 %doc AUTHORS README docs/build/html
 %{python_sitelib}/pathtools
-%{python_sitelib}/pathtools-%{version}-py%{python_version}.egg-info
+%{python_sitelib}/pathtools-%{version}.dist-info
 
 %changelog

++++++ stop-using-imp.patch ++++++
Index: pathtools-0.1.2/setup.py
===================================================================
--- pathtools-0.1.2.orig/setup.py
+++ pathtools-0.1.2/setup.py
@@ -22,12 +22,16 @@
 # THE SOFTWARE.
 
 import os
-import imp
+import importlib.machinery
+import importlib.util
 from setuptools import setup
 
 PKG_DIR = 'pathtools'
-version = imp.load_source('version',
-                          os.path.join(PKG_DIR, 'version.py'))
+path = os.path.join(PKG_DIR, 'version.py')
+loader = importlib.machinery.SourceFileLoader("pathtools", path)
+spec = importlib.util.spec_from_file_location("pathtools", path)
+version = importlib.util.module_from_spec(spec)
+loader.exec_module(version)
 
 def read_file(filename):
     """

Reply via email to