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
from importlib.resources.simple import ResourceContainer, SimpleReader
import io
class R(SimpleReader):
@property
def package(self): return 'x'
def children(self): return []
def resources(self): return []
def open_binary(self, r): return io.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