mirror of
https://github.com/python/cpython.git
synced 2025-11-01 10:45:30 +00:00
bpo-46246: add missing __slots__ to importlib.metadata.DeprecatedList (GH-30452)
Confirmed with @jaraco that this indeed needs a fix. A question that came up while I was digging into the code: I think `SelectableGroups` could similarly use `__slots__ = ()`, since its purpose seems only for convenience around `dict`, not to have attributes of its own. Automerge-Triggered-By: GH:jaraco
This commit is contained in:
parent
80e4f262aa
commit
dd76b3f7d3
3 changed files with 9 additions and 0 deletions
|
|
@ -278,6 +278,8 @@ class DeprecatedList(list):
|
|||
1
|
||||
"""
|
||||
|
||||
__slots__ = ()
|
||||
|
||||
_warn = functools.partial(
|
||||
warnings.warn,
|
||||
"EntryPoints list interface is deprecated. Cast to list if needed.",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue