Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-pkgutil-resolve-name for
openSUSE:Factory checked in at 2022-09-26 18:48:46
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pkgutil-resolve-name (Old)
and /work/SRC/openSUSE:Factory/.python-pkgutil-resolve-name.new.2275 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pkgutil-resolve-name"
Mon Sep 26 18:48:46 2022 rev:2 rq:1006183 version:1.3.10
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-pkgutil-resolve-name/python-pkgutil-resolve-name.changes
2020-12-01 14:23:13.189621437 +0100
+++
/work/SRC/openSUSE:Factory/.python-pkgutil-resolve-name.new.2275/python-pkgutil-resolve-name.changes
2022-09-26 18:48:47.768121399 +0200
@@ -1,0 +2,8 @@
+Mon Sep 26 14:32:17 UTC 2022 - Ben Greiner <[email protected]>
+
+- Update to 1.3.10
+ * no upstream changelog or release notes
+- Use PEP517 instead of flit generated distutils setup.py
+- New version required by jsonschema
+
+-------------------------------------------------------------------
Old:
----
pkgutil_resolve_name-1.0.0.tar.gz
New:
----
pkgutil_resolve_name-1.3.10.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-pkgutil-resolve-name.spec ++++++
--- /var/tmp/diff_new_pack.gHsqAL/_old 2022-09-26 18:48:48.300122405 +0200
+++ /var/tmp/diff_new_pack.gHsqAL/_new 2022-09-26 18:48:48.308122419 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-pkgutil-resolve-name
#
-# Copyright (c) 2020 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
@@ -18,14 +18,15 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-pkgutil-resolve-name
-Version: 1.0.0
+Version: 1.3.10
Release: 0
Summary: Backport of Python 3.9's pkgutil.resolve_name
-License: Python-2.0 AND MIT
+License: MIT AND Python-2.0
Group: Development/Languages/Python
URL: https://github.com/graingert/pkgutil-resolve-name
Source:
https://files.pythonhosted.org/packages/source/p/pkgutil_resolve_name/pkgutil_resolve_name-%{version}.tar.gz
-BuildRequires: %{python_module setuptools}
+BuildRequires: %{python_module flit-core}
+BuildRequires: %{python_module pip}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildArch: noarch
@@ -39,10 +40,10 @@
%setup -q -n pkgutil_resolve_name-%{version}
%build
-%python_build
+%pyproject_wheel
%install
-%python_install
+%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
# No tests provided in repo of backport
@@ -50,6 +51,8 @@
%files %{python_files}
%doc README.rst
%license LICENSE
-%{python_sitelib}/*
+%{python_sitelib}/pkgutil_resolve_name.py*
+%pycache_only %{python_sitelib}/__pycache__/pkgutil_resolve_name*.pyc
+%{python_sitelib}/pkgutil_resolve_name-%{version}*-info
%changelog
++++++ pkgutil_resolve_name-1.0.0.tar.gz -> pkgutil_resolve_name-1.3.10.tar.gz
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pkgutil_resolve_name-1.0.0/PKG-INFO
new/pkgutil_resolve_name-1.3.10/PKG-INFO
--- old/pkgutil_resolve_name-1.0.0/PKG-INFO 1970-01-01 01:00:00.000000000
+0100
+++ new/pkgutil_resolve_name-1.3.10/PKG-INFO 1970-01-01 01:00:00.000000000
+0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: pkgutil_resolve_name
-Version: 1.0.0
+Version: 1.3.10
Summary: Resolve a name to an object.
Home-page: https://github.com/graingert/pkgutil-resolve-name
Author: Vinay Sajip
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pkgutil_resolve_name-1.0.0/pkgutil_resolve_name.py
new/pkgutil_resolve_name-1.3.10/pkgutil_resolve_name.py
--- old/pkgutil_resolve_name-1.0.0/pkgutil_resolve_name.py 2020-02-19
20:00:05.838985200 +0100
+++ new/pkgutil_resolve_name-1.3.10/pkgutil_resolve_name.py 2021-07-21
10:14:28.444485400 +0200
@@ -33,22 +33,61 @@
import importlib
import re
-__version__ = "1.0.0"
+__version__ = "1.3.10"
-_DOTTED_WORDS = r'[a-z_]\w*(\.[a-z_]\w*)*'
-_NAME_PATTERN =
re.compile('^({_DOTTED_WORDS})(:({_DOTTED_WORDS})?)?$'.format(_DOTTED_WORDS=_DOTTED_WORDS),
re.I)
-del _DOTTED_WORDS
+_NAME_PATTERN = None
def resolve_name(name):
+ """
+ Resolve a name to an object.
+
+ It is expected that `name` will be a string in one of the following
+ formats, where W is shorthand for a valid Python identifier and dot stands
+ for a literal period in these pseudo-regexes:
+
+ W(.W)*
+ W(.W)*:(W(.W)*)?
+
+ The first form is intended for backward compatibility only. It assumes that
+ some part of the dotted name is a package, and the rest is an object
+ somewhere within that package, possibly nested inside other objects.
+ Because the place where the package stops and the object hierarchy starts
+ can't be inferred by inspection, repeated attempts to import must be done
+ with this form.
+
+ In the second form, the caller makes the division point clear through the
+ provision of a single colon: the dotted name to the left of the colon is a
+ package to be imported, and the dotted name to the right is the object
+ hierarchy within that package. Only one import is needed in this form. If
+ it ends with the colon, then a module object is returned.
+
+ The function will return an object (which might be a module), or raise one
+ of the following exceptions:
+
+ ValueError - if `name` isn't in a recognised format
+ ImportError - if an import failed when it shouldn't have
+ AttributeError - if a failure occurred when traversing the object hierarchy
+ within the imported package to get to the desired object)
+ """
+ global _NAME_PATTERN
+ if _NAME_PATTERN is None:
+ # Lazy import to speedup Python startup time
+ import re
+ dotted_words = r'(?!\d)(\w+)(\.(?!\d)(\w+))*'
+ _NAME_PATTERN = re.compile(f'^(?P<pkg>{dotted_words})'
+ f'(?P<cln>:(?P<obj>{dotted_words})?)?$',
+ re.UNICODE)
+
m = _NAME_PATTERN.match(name)
if not m:
- raise ValueError('invalid format: {name!r}'.format(name=name))
- groups = m.groups()
- if groups[2]:
+ raise ValueError(f'invalid format: {name!r}')
+ gd = m.groupdict()
+ if gd.get('cln'):
# there is a colon - a one-step import is all that's needed
- mod = importlib.import_module(groups[0])
- parts = groups[3].split('.') if groups[3] else []
+ mod = importlib.import_module(gd['pkg'])
+ parts = gd.get('obj')
+ parts = parts.split('.') if parts else []
else:
# no colon - have to iterate to find the package boundary
parts = name.split('.')
@@ -57,7 +96,7 @@
mod = importlib.import_module(modname)
while parts:
p = parts[0]
- s = '{modname}.{p}'.format(modname=modname, p=p)
+ s = f'{modname}.{p}'
try:
mod = importlib.import_module(s)
parts.pop(0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pkgutil_resolve_name-1.0.0/pyproject.toml
new/pkgutil_resolve_name-1.3.10/pyproject.toml
--- old/pkgutil_resolve_name-1.0.0/pyproject.toml 2020-02-19
19:59:53.063004300 +0100
+++ new/pkgutil_resolve_name-1.3.10/pyproject.toml 2021-07-21
10:14:28.444485400 +0200
@@ -11,3 +11,4 @@
maintainer-email = "[email protected]"
home-page = "https://github.com/graingert/pkgutil-resolve-name"
classifiers = ["License :: OSI Approved :: MIT License"]
+requires-python = ">=3.6"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pkgutil_resolve_name-1.0.0/setup.py
new/pkgutil_resolve_name-1.3.10/setup.py
--- old/pkgutil_resolve_name-1.0.0/setup.py 1970-01-01 01:00:00.000000000
+0100
+++ new/pkgutil_resolve_name-1.3.10/setup.py 1970-01-01 01:00:00.000000000
+0100
@@ -5,10 +5,11 @@
setup(name='pkgutil_resolve_name',
- version='1.0.0',
+ version='1.3.10',
description='Resolve a name to an object.',
author='Vinay Sajip',
author_email='[email protected]',
url='https://github.com/graingert/pkgutil-resolve-name',
py_modules=['pkgutil_resolve_name'],
+ python_requires='>=3.6',
)