Bug report
Bug description:
Issue
ResourceContainer and ResourceHandle cannot be instantiated because Traversable now declares name as an abstract property. Additionally, ResourceContainer.iterdir() accesses self.reader.resources without calling it, and ResourceHandle.joinpath has a signature mismatch with the base class.
Reproducer
fromimportlib.resources.simpleimportResourceContainer, SimpleReaderimportioclassR(SimpleReader):
@propertydefpackage(self): return'x'defchildren(self): return []
defresources(self): return []
defopen_binary(self, r): returnio.BytesIO(b'')
ResourceContainer(R()) # TypeError: Can't instantiate abstract class ResourceContainer
CPython versions tested on:
CPython main branch
Operating systems tested on:
No response
Linked PRs
Bug report
Bug description:
Issue
ResourceContainerandResourceHandlecannot be instantiated becauseTraversablenow declaresnameas an abstract property. Additionally,ResourceContainer.iterdir()accessesself.reader.resourceswithout calling it, andResourceHandle.joinpathhas a signature mismatch with the base class.Reproducer
CPython versions tested on:
CPython main branch
Operating systems tested on:
No response
Linked PRs