diff options
Diffstat (limited to 'meta/recipes-devtools/python/python3/valid-dists.patch')
| -rw-r--r-- | meta/recipes-devtools/python/python3/valid-dists.patch | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/meta/recipes-devtools/python/python3/valid-dists.patch b/meta/recipes-devtools/python/python3/valid-dists.patch index 1b2c078c21..38b6ebc5cb 100644 --- a/meta/recipes-devtools/python/python3/valid-dists.patch +++ b/meta/recipes-devtools/python/python3/valid-dists.patch | |||
| @@ -8,12 +8,16 @@ Closes python/importlib_metadata#489 | |||
| 8 | 8 | ||
| 9 | Upstream-Status: Backport [https://github.com/python/importlib_metadata/commit/a65c29adc027b3615154cab73aaedd58a6aa23da] | 9 | Upstream-Status: Backport [https://github.com/python/importlib_metadata/commit/a65c29adc027b3615154cab73aaedd58a6aa23da] |
| 10 | Signed-off-by: Ross Burton <ross.burton@arm.com> | 10 | Signed-off-by: Ross Burton <ross.burton@arm.com> |
| 11 | --- | ||
| 12 | Lib/importlib/metadata/__init__.py | 14 +++- | ||
| 13 | Lib/importlib/metadata/_itertools.py | 98 ++++++++++++++++++++++++++++ | ||
| 14 | 2 files changed, 110 insertions(+), 2 deletions(-) | ||
| 11 | 15 | ||
| 12 | diff --git i/Lib/importlib/metadata/__init__.py w/Lib/importlib/metadata/__init__.py | 16 | diff --git a/Lib/importlib/metadata/__init__.py b/Lib/importlib/metadata/__init__.py |
| 13 | index 8ce62dd864f..085378caabc 100644 | 17 | index 8ce62dd..085378c 100644 |
| 14 | --- i/Lib/importlib/metadata/__init__.py | 18 | --- a/Lib/importlib/metadata/__init__.py |
| 15 | +++ w/Lib/importlib/metadata/__init__.py | 19 | +++ b/Lib/importlib/metadata/__init__.py |
| 16 | @@ -21,7 +21,7 @@ | 20 | @@ -21,7 +21,7 @@ import collections |
| 17 | from . import _meta | 21 | from . import _meta |
| 18 | from ._collections import FreezableDefaultDict, Pair | 22 | from ._collections import FreezableDefaultDict, Pair |
| 19 | from ._functools import method_cache, pass_none | 23 | from ._functools import method_cache, pass_none |
| @@ -22,7 +26,7 @@ index 8ce62dd864f..085378caabc 100644 | |||
| 22 | from ._meta import PackageMetadata, SimplePath | 26 | from ._meta import PackageMetadata, SimplePath |
| 23 | 27 | ||
| 24 | from contextlib import suppress | 28 | from contextlib import suppress |
| 25 | @@ -404,7 +404,7 @@ def from_name(cls, name: str) -> Distribution: | 29 | @@ -404,7 +404,7 @@ class Distribution(DeprecatedNonAbstract): |
| 26 | if not name: | 30 | if not name: |
| 27 | raise ValueError("A distribution name is required.") | 31 | raise ValueError("A distribution name is required.") |
| 28 | try: | 32 | try: |
| @@ -31,7 +35,7 @@ index 8ce62dd864f..085378caabc 100644 | |||
| 31 | except StopIteration: | 35 | except StopIteration: |
| 32 | raise PackageNotFoundError(name) | 36 | raise PackageNotFoundError(name) |
| 33 | 37 | ||
| 34 | @@ -428,6 +428,16 @@ def discover( | 38 | @@ -428,6 +428,16 @@ class Distribution(DeprecatedNonAbstract): |
| 35 | resolver(context) for resolver in cls._discover_resolvers() | 39 | resolver(context) for resolver in cls._discover_resolvers() |
| 36 | ) | 40 | ) |
| 37 | 41 | ||
| @@ -48,10 +52,10 @@ index 8ce62dd864f..085378caabc 100644 | |||
| 48 | @staticmethod | 52 | @staticmethod |
| 49 | def at(path: str | os.PathLike[str]) -> Distribution: | 53 | def at(path: str | os.PathLike[str]) -> Distribution: |
| 50 | """Return a Distribution for the indicated metadata path. | 54 | """Return a Distribution for the indicated metadata path. |
| 51 | diff --git i/Lib/importlib/metadata/_itertools.py w/Lib/importlib/metadata/_itertools.py | 55 | diff --git a/Lib/importlib/metadata/_itertools.py b/Lib/importlib/metadata/_itertools.py |
| 52 | index d4ca9b9140e..79d37198ce7 100644 | 56 | index d4ca9b9..79d3719 100644 |
| 53 | --- i/Lib/importlib/metadata/_itertools.py | 57 | --- a/Lib/importlib/metadata/_itertools.py |
| 54 | +++ w/Lib/importlib/metadata/_itertools.py | 58 | +++ b/Lib/importlib/metadata/_itertools.py |
| 55 | @@ -1,3 +1,4 @@ | 59 | @@ -1,3 +1,4 @@ |
| 56 | +from collections import defaultdict, deque | 60 | +from collections import defaultdict, deque |
| 57 | from itertools import filterfalse | 61 | from itertools import filterfalse |
