Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-importlib-metadata for
openSUSE:Factory checked in at 2026-03-24 18:47:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-importlib-metadata (Old)
and /work/SRC/openSUSE:Factory/.python-importlib-metadata.new.8177 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-importlib-metadata"
Tue Mar 24 18:47:57 2026 rev:31 rq:1342029 version:9.0.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-importlib-metadata/python-importlib-metadata.changes
2026-01-13 21:23:37.752862594 +0100
+++
/work/SRC/openSUSE:Factory/.python-importlib-metadata.new.8177/python-importlib-metadata.changes
2026-03-24 18:48:05.780564781 +0100
@@ -1,0 +2,10 @@
+Mon Mar 23 11:56:25 UTC 2026 - Dirk Müller <[email protected]>
+
+- update to 9.0.0:
+ * Added MetadataNotFound (subclass of FileNotFoundError) and
+ updated Distribution.metadata/metadata() to raise it when the
+ metadata files are missing instead of returning None
+ (python/cpython#143387).
+ * Removed Python 3.9 compatibility.
+
+-------------------------------------------------------------------
Old:
----
importlib_metadata-8.7.1.tar.gz
New:
----
importlib_metadata-9.0.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-importlib-metadata.spec ++++++
--- /var/tmp/diff_new_pack.ZPBjIp/_old 2026-03-24 18:48:06.412590403 +0100
+++ /var/tmp/diff_new_pack.ZPBjIp/_new 2026-03-24 18:48:06.416590565 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-importlib-metadata
#
-# Copyright (c) 2025 SUSE LLC
+# Copyright (c) 2026 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -26,7 +26,7 @@
%endif
%{?sle15_python_module_pythons}
Name: python-importlib-metadata%{psuffix}
-Version: 8.7.1
+Version: 9.0.0
Release: 0
Summary: Read metadata from Python packages
License: Apache-2.0
++++++ importlib_metadata-8.7.1.tar.gz -> importlib_metadata-9.0.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/.github/workflows/main.yml
new/importlib_metadata-9.0.0/.github/workflows/main.yml
--- old/importlib_metadata-8.7.1/.github/workflows/main.yml 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/.github/workflows/main.yml 2026-03-20
07:42:33.000000000 +0100
@@ -34,31 +34,31 @@
# https://blog.jaraco.com/efficient-use-of-ci-resources/
matrix:
python:
- - "3.9"
+ - "3.10"
- "3.13"
platform:
- ubuntu-latest
- macos-latest
- windows-latest
include:
- - python: "3.10"
- platform: ubuntu-latest
- python: "3.11"
platform: ubuntu-latest
- python: "3.12"
platform: ubuntu-latest
- python: "3.14"
platform: ubuntu-latest
+ - python: "3.15"
+ platform: ubuntu-latest
- python: pypy3.10
platform: ubuntu-latest
runs-on: ${{ matrix.platform }}
- continue-on-error: ${{ matrix.python == '3.14' }}
+ continue-on-error: ${{ matrix.python == '3.15' }}
steps:
- uses: actions/checkout@v4
- name: Install build dependencies
# Install dependencies for building packages on pre-release Pythons
# jaraco/skeleton#161
- if: matrix.python == '3.14' && matrix.platform == 'ubuntu-latest'
+ if: matrix.python == '3.15' && matrix.platform == 'ubuntu-latest'
run: |
sudo apt update
sudo apt install -y libxml2-dev libxslt-dev
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/.pre-commit-config.yaml
new/importlib_metadata-9.0.0/.pre-commit-config.yaml
--- old/importlib_metadata-8.7.1/.pre-commit-config.yaml 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/.pre-commit-config.yaml 2026-03-20
07:42:33.000000000 +0100
@@ -2,6 +2,6 @@
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.0
hooks:
- - id: ruff
+ - id: ruff-check
args: [--fix, --unsafe-fixes]
- id: ruff-format
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/LICENSE
new/importlib_metadata-9.0.0/LICENSE
--- old/importlib_metadata-8.7.1/LICENSE 2025-12-21 11:00:13.000000000
+0100
+++ new/importlib_metadata-9.0.0/LICENSE 2026-03-20 07:42:51.000000000
+0100
@@ -58,7 +58,7 @@
To apply the Apache License to your work, attach the following boilerplate
notice, with the fields enclosed by brackets "[]" replaced with your own
identifying information. (Don't include the brackets!) The text should be
enclosed in the appropriate comment syntax for the file format. We also
recommend that a file or class name and description of purpose be included on
the same "printed page" as the copyright notice for easier identification
within third-party archives.
-Copyright 2025 [name of copyright owner]
+Copyright 2026 [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/NEWS.rst
new/importlib_metadata-9.0.0/NEWS.rst
--- old/importlib_metadata-8.7.1/NEWS.rst 2025-12-21 10:59:52.000000000
+0100
+++ new/importlib_metadata-9.0.0/NEWS.rst 2026-03-20 07:42:33.000000000
+0100
@@ -1,3 +1,21 @@
+v9.0.0
+======
+
+Deprecations and Removals
+-------------------------
+
+- Added ``MetadataNotFound`` (subclass of ``FileNotFoundError``) and updated
``Distribution.metadata``/``metadata()`` to raise it when the metadata files
are missing instead of returning ``None`` (python/cpython#143387). (#532)
+
+
+v8.8.0
+======
+
+Features
+--------
+
+- Removed Python 3.9 compatibility.
+
+
v8.7.1
======
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/PKG-INFO
new/importlib_metadata-9.0.0/PKG-INFO
--- old/importlib_metadata-8.7.1/PKG-INFO 2025-12-21 11:00:13.847653000
+0100
+++ new/importlib_metadata-9.0.0/PKG-INFO 2026-03-20 07:42:51.991946700
+0100
@@ -1,6 +1,6 @@
Metadata-Version: 2.4
Name: importlib_metadata
-Version: 8.7.1
+Version: 9.0.0
Summary: Read metadata from Python packages
Author-email: "Jason R. Coombs" <[email protected]>
License-Expression: Apache-2.0
@@ -9,7 +9,7 @@
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
-Requires-Python: >=3.9
+Requires-Python: >=3.10
Description-Content-Type: text/x-rst
License-File: LICENSE
Requires-Dist: zipp>=3.20
@@ -17,9 +17,7 @@
Requires-Dist: pytest!=8.1.*,>=6; extra == "test"
Requires-Dist: packaging; extra == "test"
Requires-Dist: pyfakefs; extra == "test"
-Requires-Dist: flufl.flake8; extra == "test"
Requires-Dist: pytest-perf>=0.9.2; extra == "test"
-Requires-Dist: jaraco.test>=5.4; extra == "test"
Provides-Extra: doc
Requires-Dist: sphinx>=3.5; extra == "doc"
Requires-Dist: jaraco.packaging>=9.3; extra == "doc"
@@ -30,15 +28,14 @@
Provides-Extra: perf
Requires-Dist: ipython; extra == "perf"
Provides-Extra: check
-Requires-Dist: pytest-checkdocs>=2.4; extra == "check"
+Requires-Dist: pytest-checkdocs>=2.14; extra == "check"
Requires-Dist: pytest-ruff>=0.2.1; sys_platform != "cygwin" and extra ==
"check"
Provides-Extra: cover
Requires-Dist: pytest-cov; extra == "cover"
Provides-Extra: enabler
Requires-Dist: pytest-enabler>=3.4; extra == "enabler"
Provides-Extra: type
-Requires-Dist: pytest-mypy>=1.0.1; extra == "type"
-Requires-Dist: mypy<1.19; platform_python_implementation == "PyPy" and extra
== "type"
+Requires-Dist: pytest-mypy>=1.0.1; platform_python_implementation != "PyPy"
and extra == "type"
Dynamic: license-file
.. image:: https://img.shields.io/pypi/v/importlib_metadata.svg
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata/__init__.py
new/importlib_metadata-9.0.0/importlib_metadata/__init__.py
--- old/importlib_metadata-8.7.1/importlib_metadata/__init__.py 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata/__init__.py 2026-03-20
07:42:33.000000000 +0100
@@ -35,17 +35,18 @@
NullFinder,
install,
)
+from ._context import ExceptionTrap
from ._functools import method_cache, noop, pass_none, passthrough
from ._itertools import always_iterable, bucket, unique_everseen
from ._meta import PackageMetadata, SimplePath
-from ._typing import md_none
-from .compat import py39, py311
+from .compat import py311
__all__ = [
'Distribution',
'DistributionFinder',
'PackageMetadata',
'PackageNotFoundError',
+ 'MetadataNotFound',
'SimplePath',
'distribution',
'distributions',
@@ -70,6 +71,10 @@
return name
+class MetadataNotFound(FileNotFoundError):
+ """No metadata file is present in the distribution."""
+
+
class Sectioned:
"""
A simple entry point config parser for performance
@@ -340,7 +345,7 @@
Select entry points from self that match the
given parameters (typically group and/or name).
"""
- return EntryPoints(ep for ep in self if py39.ep_matches(ep, **params))
+ return EntryPoints(ep for ep in self if ep.matches(**params))
@property
def names(self) -> set[str]:
@@ -491,7 +496,12 @@
Ref python/importlib_resources#489.
"""
- buckets = bucket(dists, lambda dist: bool(dist.metadata))
+
+ has_metadata = ExceptionTrap(MetadataNotFound).passes(
+ operator.attrgetter('metadata')
+ )
+
+ buckets = bucket(dists, has_metadata)
return itertools.chain(buckets[True], buckets[False])
@staticmethod
@@ -512,7 +522,7 @@
return filter(None, declared)
@property
- def metadata(self) -> _meta.PackageMetadata | None:
+ def metadata(self) -> _meta.PackageMetadata:
"""Return the parsed metadata for this Distribution.
The returned object will have keys that name the various bits of
@@ -521,6 +531,8 @@
Custom providers may provide the METADATA file or override this
property.
+
+ :raises MetadataNotFound: If no metadata file is present.
"""
text = (
@@ -531,20 +543,25 @@
# (which points to the egg-info file) attribute unchanged.
or self.read_text('')
)
- return self._assemble_message(text)
+ return self._assemble_message(self._ensure_metadata_present(text))
@staticmethod
- @pass_none
def _assemble_message(text: str) -> _meta.PackageMetadata:
# deferred for performance (python/cpython#109829)
from . import _adapters
return _adapters.Message(email.message_from_string(text))
+ def _ensure_metadata_present(self, text: str | None) -> str:
+ if text is not None:
+ return text
+
+ raise MetadataNotFound('No package metadata was found.')
+
@property
def name(self) -> str:
"""Return the 'Name' metadata for the distribution package."""
- return md_none(self.metadata)['Name']
+ return self.metadata['Name']
@property
def _normalized_name(self):
@@ -554,7 +571,7 @@
@property
def version(self) -> str:
"""Return the 'Version' metadata for the distribution package."""
- return md_none(self.metadata)['Version']
+ return self.metadata['Version']
@property
def entry_points(self) -> EntryPoints:
@@ -1067,11 +1084,12 @@
return Distribution.discover(**kwargs)
-def metadata(distribution_name: str) -> _meta.PackageMetadata | None:
+def metadata(distribution_name: str) -> _meta.PackageMetadata:
"""Get the metadata for the named package.
:param distribution_name: The name of the distribution package to query.
:return: A PackageMetadata containing the parsed metadata.
+ :raises MetadataNotFound: If no metadata file is present in the
distribution.
"""
return Distribution.from_name(distribution_name).metadata
@@ -1088,7 +1106,7 @@
_unique = functools.partial(
unique_everseen,
- key=py39.normalized_name,
+ key=operator.attrgetter('_normalized_name'),
)
"""
Wrapper for ``distributions`` to return unique distributions by name.
@@ -1142,7 +1160,7 @@
pkg_to_dist = collections.defaultdict(list)
for dist in distributions():
for pkg in _top_level_declared(dist) or _top_level_inferred(dist):
- pkg_to_dist[pkg].append(md_none(dist.metadata)['Name'])
+ pkg_to_dist[pkg].append(dist.metadata['Name'])
return dict(pkg_to_dist)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata/_context.py
new/importlib_metadata-9.0.0/importlib_metadata/_context.py
--- old/importlib_metadata-8.7.1/importlib_metadata/_context.py 1970-01-01
01:00:00.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata/_context.py 2026-03-20
07:42:33.000000000 +0100
@@ -0,0 +1,118 @@
+from __future__ import annotations
+
+import functools
+import operator
+
+
+# from jaraco.context 6.1
+class ExceptionTrap:
+ """
+ A context manager that will catch certain exceptions and provide an
+ indication they occurred.
+
+ >>> with ExceptionTrap() as trap:
+ ... raise Exception()
+ >>> bool(trap)
+ True
+
+ >>> with ExceptionTrap() as trap:
+ ... pass
+ >>> bool(trap)
+ False
+
+ >>> with ExceptionTrap(ValueError) as trap:
+ ... raise ValueError("1 + 1 is not 3")
+ >>> bool(trap)
+ True
+ >>> trap.value
+ ValueError('1 + 1 is not 3')
+ >>> trap.tb
+ <traceback object at ...>
+
+ >>> with ExceptionTrap(ValueError) as trap:
+ ... raise Exception()
+ Traceback (most recent call last):
+ ...
+ Exception
+
+ >>> bool(trap)
+ False
+ """
+
+ exc_info = None, None, None
+
+ def __init__(self, exceptions=(Exception,)):
+ self.exceptions = exceptions
+
+ def __enter__(self):
+ return self
+
+ @property
+ def type(self):
+ return self.exc_info[0]
+
+ @property
+ def value(self):
+ return self.exc_info[1]
+
+ @property
+ def tb(self):
+ return self.exc_info[2]
+
+ def __exit__(self, *exc_info):
+ type = exc_info[0]
+ matches = type and issubclass(type, self.exceptions)
+ if matches:
+ self.exc_info = exc_info
+ return matches
+
+ def __bool__(self):
+ return bool(self.type)
+
+ def raises(self, func, *, _test=bool):
+ """
+ Wrap func and replace the result with the truth
+ value of the trap (True if an exception occurred).
+
+ First, give the decorator an alias to support Python 3.8
+ Syntax.
+
+ >>> raises = ExceptionTrap(ValueError).raises
+
+ Now decorate a function that always fails.
+
+ >>> @raises
+ ... def fail():
+ ... raise ValueError('failed')
+ >>> fail()
+ True
+ """
+
+ @functools.wraps(func)
+ def wrapper(*args, **kwargs):
+ with ExceptionTrap(self.exceptions) as trap:
+ func(*args, **kwargs)
+ return _test(trap)
+
+ return wrapper
+
+ def passes(self, func):
+ """
+ Wrap func and replace the result with the truth
+ value of the trap (True if no exception).
+
+ First, give the decorator an alias to support Python 3.8
+ Syntax.
+
+ >>> passes = ExceptionTrap(ValueError).passes
+
+ Now decorate a function that always fails.
+
+ >>> @passes
+ ... def fail():
+ ... raise ValueError('failed')
+
+ >>> fail()
+ False
+ """
+ return self.raises(func, _test=operator.not_)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata/_functools.py
new/importlib_metadata-9.0.0/importlib_metadata/_functools.py
--- old/importlib_metadata-8.7.1/importlib_metadata/_functools.py
2025-12-21 10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata/_functools.py
2026-03-20 07:42:33.000000000 +0100
@@ -1,6 +1,7 @@
import functools
import types
-from typing import Callable, TypeVar
+from collections.abc import Callable
+from typing import TypeVar
# from jaraco.functools 3.3
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata/_typing.py
new/importlib_metadata-9.0.0/importlib_metadata/_typing.py
--- old/importlib_metadata-8.7.1/importlib_metadata/_typing.py 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata/_typing.py 1970-01-01
01:00:00.000000000 +0100
@@ -1,15 +0,0 @@
-import functools
-import typing
-
-from ._meta import PackageMetadata
-
-md_none = functools.partial(typing.cast, PackageMetadata)
-"""
-Suppress type errors for optional metadata.
-
-Although Distribution.metadata can return None when metadata is corrupt
-and thus None, allow callers to assume it's not None and crash if
-that's the case.
-
-# python/importlib_metadata#493
-"""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata/compat/py39.py
new/importlib_metadata-9.0.0/importlib_metadata/compat/py39.py
--- old/importlib_metadata-8.7.1/importlib_metadata/compat/py39.py
2025-12-21 10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata/compat/py39.py
1970-01-01 01:00:00.000000000 +0100
@@ -1,42 +0,0 @@
-"""
-Compatibility layer with Python 3.8/3.9
-"""
-
-from __future__ import annotations
-
-from typing import TYPE_CHECKING, Any
-
-if TYPE_CHECKING: # pragma: no cover
- # Prevent circular imports on runtime.
- from .. import Distribution, EntryPoint
-else:
- Distribution = EntryPoint = Any
-
-from .._typing import md_none
-
-
-def normalized_name(dist: Distribution) -> str | None:
- """
- Honor name normalization for distributions that don't provide
``_normalized_name``.
- """
- try:
- return dist._normalized_name
- except AttributeError:
- from .. import Prepared # -> delay to prevent circular imports.
-
- return Prepared.normalize(
- getattr(dist, "name", None) or md_none(dist.metadata)['Name']
- )
-
-
-def ep_matches(ep: EntryPoint, **params) -> bool:
- """
- Workaround for ``EntryPoint`` objects without the ``matches`` method.
- """
- try:
- return ep.matches(**params)
- except AttributeError:
- from .. import EntryPoint # -> delay to prevent circular imports.
-
- # Reconstruct the EntryPoint object to make sure it is compatible.
- return EntryPoint(ep.name, ep.value, ep.group).matches(**params)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata.egg-info/PKG-INFO
new/importlib_metadata-9.0.0/importlib_metadata.egg-info/PKG-INFO
--- old/importlib_metadata-8.7.1/importlib_metadata.egg-info/PKG-INFO
2025-12-21 11:00:13.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata.egg-info/PKG-INFO
2026-03-20 07:42:51.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 2.4
Name: importlib_metadata
-Version: 8.7.1
+Version: 9.0.0
Summary: Read metadata from Python packages
Author-email: "Jason R. Coombs" <[email protected]>
License-Expression: Apache-2.0
@@ -9,7 +9,7 @@
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
-Requires-Python: >=3.9
+Requires-Python: >=3.10
Description-Content-Type: text/x-rst
License-File: LICENSE
Requires-Dist: zipp>=3.20
@@ -17,9 +17,7 @@
Requires-Dist: pytest!=8.1.*,>=6; extra == "test"
Requires-Dist: packaging; extra == "test"
Requires-Dist: pyfakefs; extra == "test"
-Requires-Dist: flufl.flake8; extra == "test"
Requires-Dist: pytest-perf>=0.9.2; extra == "test"
-Requires-Dist: jaraco.test>=5.4; extra == "test"
Provides-Extra: doc
Requires-Dist: sphinx>=3.5; extra == "doc"
Requires-Dist: jaraco.packaging>=9.3; extra == "doc"
@@ -30,15 +28,14 @@
Provides-Extra: perf
Requires-Dist: ipython; extra == "perf"
Provides-Extra: check
-Requires-Dist: pytest-checkdocs>=2.4; extra == "check"
+Requires-Dist: pytest-checkdocs>=2.14; extra == "check"
Requires-Dist: pytest-ruff>=0.2.1; sys_platform != "cygwin" and extra ==
"check"
Provides-Extra: cover
Requires-Dist: pytest-cov; extra == "cover"
Provides-Extra: enabler
Requires-Dist: pytest-enabler>=3.4; extra == "enabler"
Provides-Extra: type
-Requires-Dist: pytest-mypy>=1.0.1; extra == "type"
-Requires-Dist: mypy<1.19; platform_python_implementation == "PyPy" and extra
== "type"
+Requires-Dist: pytest-mypy>=1.0.1; platform_python_implementation != "PyPy"
and extra == "type"
Dynamic: license-file
.. image:: https://img.shields.io/pypi/v/importlib_metadata.svg
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata.egg-info/SOURCES.txt
new/importlib_metadata-9.0.0/importlib_metadata.egg-info/SOURCES.txt
--- old/importlib_metadata-8.7.1/importlib_metadata.egg-info/SOURCES.txt
2025-12-21 11:00:13.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata.egg-info/SOURCES.txt
2026-03-20 07:42:51.000000000 +0100
@@ -27,11 +27,11 @@
importlib_metadata/_adapters.py
importlib_metadata/_collections.py
importlib_metadata/_compat.py
+importlib_metadata/_context.py
importlib_metadata/_functools.py
importlib_metadata/_itertools.py
importlib_metadata/_meta.py
importlib_metadata/_text.py
-importlib_metadata/_typing.py
importlib_metadata/diagnose.py
importlib_metadata/py.typed
importlib_metadata.egg-info/PKG-INFO
@@ -41,7 +41,6 @@
importlib_metadata.egg-info/top_level.txt
importlib_metadata/compat/__init__.py
importlib_metadata/compat/py311.py
-importlib_metadata/compat/py39.py
tests/__init__.py
tests/_context.py
tests/_path.py
@@ -52,8 +51,6 @@
tests/test_zip.py
tests/compat/__init__.py
tests/compat/py312.py
-tests/compat/py39.py
-tests/compat/test_py39_compat.py
tests/data/__init__.py
tests/data/example-21.12-py3-none-any.whl
tests/data/example-21.12-py3.6.egg
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/importlib_metadata.egg-info/requires.txt
new/importlib_metadata-9.0.0/importlib_metadata.egg-info/requires.txt
--- old/importlib_metadata-8.7.1/importlib_metadata.egg-info/requires.txt
2025-12-21 11:00:13.000000000 +0100
+++ new/importlib_metadata-9.0.0/importlib_metadata.egg-info/requires.txt
2026-03-20 07:42:51.000000000 +0100
@@ -1,7 +1,7 @@
zipp>=3.20
[check]
-pytest-checkdocs>=2.4
+pytest-checkdocs>=2.14
[check:sys_platform != "cygwin"]
pytest-ruff>=0.2.1
@@ -27,12 +27,9 @@
pytest!=8.1.*,>=6
packaging
pyfakefs
-flufl.flake8
pytest-perf>=0.9.2
-jaraco.test>=5.4
[type]
-pytest-mypy>=1.0.1
-[type:platform_python_implementation == "PyPy"]
-mypy<1.19
+[type:platform_python_implementation != "PyPy"]
+pytest-mypy>=1.0.1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/mypy.ini
new/importlib_metadata-9.0.0/mypy.ini
--- old/importlib_metadata-8.7.1/mypy.ini 2025-12-21 10:59:52.000000000
+0100
+++ new/importlib_metadata-9.0.0/mypy.ini 2026-03-20 07:42:33.000000000
+0100
@@ -22,6 +22,5 @@
[mypy-zipp.*]
ignore_missing_imports = True
-# jaraco/jaraco.test#7
-[mypy-jaraco.test.*]
+[mypy-test.support.*]
ignore_missing_imports = True
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/pyproject.toml
new/importlib_metadata-9.0.0/pyproject.toml
--- old/importlib_metadata-8.7.1/pyproject.toml 2025-12-21 10:59:52.000000000
+0100
+++ new/importlib_metadata-9.0.0/pyproject.toml 2026-03-20 07:42:33.000000000
+0100
@@ -20,7 +20,7 @@
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
]
-requires-python = ">=3.9"
+requires-python = ">=3.10"
license = "Apache-2.0"
dependencies = [
"zipp>=3.20",
@@ -38,9 +38,7 @@
# local
"packaging",
"pyfakefs",
- "flufl.flake8",
"pytest-perf >= 0.9.2",
- "jaraco.test >= 5.4",
]
doc = [
@@ -59,7 +57,7 @@
perf = ["ipython"]
check = [
- "pytest-checkdocs >= 2.4",
+ "pytest-checkdocs >= 2.14",
"pytest-ruff >= 0.2.1; sys_platform != 'cygwin'",
]
@@ -73,10 +71,9 @@
type = [
# upstream
- "pytest-mypy >= 1.0.1",
-
- ## workaround for python/mypy#20454
- "mypy < 1.19; python_implementation == 'PyPy'",
+
+ # Exclude PyPy from type checks (python/mypy#20454 jaraco/skeleton#187)
+ "pytest-mypy >= 1.0.1; platform_python_implementation != 'PyPy'",
# local
]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/tests/compat/py312.py
new/importlib_metadata-9.0.0/tests/compat/py312.py
--- old/importlib_metadata-8.7.1/tests/compat/py312.py 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/tests/compat/py312.py 2026-03-20
07:42:33.000000000 +0100
@@ -1,6 +1,6 @@
import contextlib
-from .py39 import import_helper
+from test.support import import_helper
@contextlib.contextmanager
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/tests/compat/py39.py
new/importlib_metadata-9.0.0/tests/compat/py39.py
--- old/importlib_metadata-8.7.1/tests/compat/py39.py 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/tests/compat/py39.py 1970-01-01
01:00:00.000000000 +0100
@@ -1,8 +0,0 @@
-from jaraco.test.cpython import from_test_support, try_import
-
-os_helper = try_import('os_helper') or from_test_support(
- 'FS_NONASCII', 'skip_unless_symlink', 'temp_dir'
-)
-import_helper = try_import('import_helper') or from_test_support(
- 'modules_setup', 'modules_cleanup'
-)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/importlib_metadata-8.7.1/tests/compat/test_py39_compat.py
new/importlib_metadata-9.0.0/tests/compat/test_py39_compat.py
--- old/importlib_metadata-8.7.1/tests/compat/test_py39_compat.py
2025-12-21 10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/tests/compat/test_py39_compat.py
1970-01-01 01:00:00.000000000 +0100
@@ -1,74 +0,0 @@
-import pathlib
-import sys
-import unittest
-
-from importlib_metadata import (
- distribution,
- distributions,
- entry_points,
- metadata,
- version,
-)
-
-from .. import fixtures
-
-
-class OldStdlibFinderTests(fixtures.DistInfoPkgOffPath, unittest.TestCase):
- def setUp(self):
- if sys.version_info >= (3, 10):
- self.skipTest("Tests specific for Python 3.8/3.9")
- super().setUp()
-
- def _meta_path_finder(self):
- from importlib.metadata import (
- Distribution,
- DistributionFinder,
- PathDistribution,
- )
- from importlib.util import spec_from_file_location
-
- path = pathlib.Path(self.site_dir)
-
- class CustomDistribution(Distribution):
- def __init__(self, name, path):
- self.name = name
- self._path_distribution = PathDistribution(path)
-
- def read_text(self, filename):
- return self._path_distribution.read_text(filename)
-
- def locate_file(self, path):
- return self._path_distribution.locate_file(path)
-
- class CustomFinder:
- @classmethod
- def find_spec(cls, fullname, _path=None, _target=None):
- candidate = pathlib.Path(path,
*fullname.split(".")).with_suffix(".py")
- if candidate.exists():
- return spec_from_file_location(fullname, candidate)
-
- @classmethod
- def find_distributions(self, context=DistributionFinder.Context()):
- for dist_info in path.glob("*.dist-info"):
- yield PathDistribution(dist_info)
- name, _, _ = str(dist_info).partition("-")
- yield CustomDistribution(name + "_custom", dist_info)
-
- return CustomFinder
-
- def test_compatibility_with_old_stdlib_path_distribution(self):
- """
- Given a custom finder that uses Python 3.8/3.9 importlib.metadata is
installed,
- when importlib_metadata functions are called, there should be no
exceptions.
- Ref python/importlib_metadata#396.
- """
-
self.fixtures.enter_context(fixtures.install_finder(self._meta_path_finder()))
-
- assert list(distributions())
- assert distribution("distinfo_pkg")
- assert distribution("distinfo_pkg_custom")
- assert version("distinfo_pkg") > "0"
- assert version("distinfo_pkg_custom") > "0"
- assert list(metadata("distinfo_pkg"))
- assert list(metadata("distinfo_pkg_custom"))
- assert list(entry_points(group="entries"))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/tests/fixtures.py
new/importlib_metadata-9.0.0/tests/fixtures.py
--- old/importlib_metadata-8.7.1/tests/fixtures.py 2025-12-21
10:59:52.000000000 +0100
+++ new/importlib_metadata-9.0.0/tests/fixtures.py 2026-03-20
07:42:33.000000000 +0100
@@ -8,9 +8,10 @@
import textwrap
from importlib import resources
+from test.support import os_helper
+
from . import _path
from ._path import FilesSpec
-from .compat.py39 import os_helper
from .compat.py312 import import_helper
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/tests/test_main.py
new/importlib_metadata-9.0.0/tests/test_main.py
--- old/importlib_metadata-8.7.1/tests/test_main.py 2025-12-21
10:59:53.000000000 +0100
+++ new/importlib_metadata-9.0.0/tests/test_main.py 2026-03-20
07:42:33.000000000 +0100
@@ -4,11 +4,13 @@
import unittest
import pyfakefs.fake_filesystem_unittest as ffs
+from test.support import os_helper
import importlib_metadata
from importlib_metadata import (
Distribution,
EntryPoint,
+ MetadataNotFound,
PackageNotFoundError,
_unique,
distributions,
@@ -20,7 +22,6 @@
from . import fixtures
from ._path import Symlink
-from .compat.py39 import os_helper
class BasicTests(fixtures.DistInfoPkg, unittest.TestCase):
@@ -157,13 +158,15 @@
def test_missing_metadata(self):
"""
- Dists with a missing metadata file should return None.
+ Dists with a missing metadata file should raise ``MetadataNotFound``.
- Ref python/importlib_metadata#493.
+ Ref python/importlib_metadata#493 and python/cpython#143387.
"""
fixtures.build_files(self.make_pkg('foo-4.3', files={}), self.site_dir)
- assert Distribution.from_name('foo').metadata is None
- assert metadata('foo') is None
+ with self.assertRaises(MetadataNotFound):
+ Distribution.from_name('foo').metadata
+ with self.assertRaises(MetadataNotFound):
+ metadata('foo')
class NonASCIITests(fixtures.OnSysPath, fixtures.SiteDir, unittest.TestCase):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/importlib_metadata-8.7.1/tox.ini
new/importlib_metadata-9.0.0/tox.ini
--- old/importlib_metadata-8.7.1/tox.ini 2025-12-21 10:59:53.000000000
+0100
+++ new/importlib_metadata-9.0.0/tox.ini 2026-03-20 07:42:33.000000000
+0100
@@ -22,7 +22,7 @@
diff-cover
commands =
pytest {posargs} --cov-report xml
- diff-cover coverage.xml --compare-branch=origin/main --html-report
diffcov.html
+ diff-cover coverage.xml --compare-branch=origin/main --format
html:diffcov.html
diff-cover coverage.xml --compare-branch=origin/main --fail-under=100
[testenv:docs]