New submission from Ronny Pfannschmidt <bugs.python....@ronnypfannschmidt.de>:
due to ``` def __iter__(self): """ Supply iter so one may construct dicts of EntryPoints easily. """ return iter((self.name, self)) ``` the default namedtuple asdict method is broken instead of returning the fields, recursive objects are returned as ``` (Pdb) v EntryPoint(name='.git', value='setuptools_scm.git:parse', group='setuptools_scm.parse_scm') (Pdb) v._asdict() {'name': '.git', 'value': EntryPoint(name='.git', value='setuptools_scm.git:parse', group='setuptools_scm.parse_scm')} (Pdb) type(v) <class 'importlib.metadata.EntryPoint'> (Pdb) ---------- components: Library (Lib) messages: 399419 nosy: Ronny.Pfannschmidt priority: normal severity: normal status: open title: importlib.metadata Entrypoint has a broken _asdict type: behavior versions: Python 3.10, Python 3.11, Python 3.8, Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue44893> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com