[New-bugs-announce] [issue47142] Document importlib.resources.abc.Traversable
Petr Viktorin
report at bugs.python.org
Mon Mar 28 08:48:15 EDT 2022
New submission from Petr Viktorin <encukou at gmail.com>:
importlib.resources.files is documented [0] as returning importlib.resources.abc.Traversable, which is an undocumented class (dead link) now. It should be documented.
The [source] has helpful docstrings, but is missing some details. I'd like to know these before writing some docs:
- Can the argument to `joinpath` contain path separators?
- Are the methods expected to raise specific exception types (e.g. if a resource is missing, or you call iterdir on a “file”)? This seems quite important for people who implement the protocol.
[0]: https://docs.python.org/dev/library/importlib.resources.html#importlib.resources.files
[source]: https://github.com/python/cpython/blob/main/Lib/importlib/resources/abc.py#L49
----------
assignee: docs at python
components: Documentation
messages: 416164
nosy: docs at python, jaraco, petr.viktorin
priority: normal
severity: normal
status: open
title: Document importlib.resources.abc.Traversable
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue47142>
_______________________________________
More information about the New-bugs-announce
mailing list