FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-89679: improve TraversableResources's documentation by FFY00 · Pull Request #29174 · python/cpython · GitHub

Repository navigation

gh-89679: improve TraversableResources's documentation - #29174

Open
FFY00 wants to merge 2 commits into
python:mainfrom
FFY00:bpo-45516-traversableresources-docstring
Open

FFY00 wants to merge 2 commits into
python:mainfrom
FFY00:bpo-45516-traversableresources-docstring

Conversation

FFY00 commented Oct 22, 2021 •
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Member

This was my attempt at rewriting TraversableResources description to make it a bit clearer to people who are not familiar with the other protocols. I don't think I did a great job, but hopefully is a bit better.

Does anyone have any suggestions on how to improve this?

https://bugs.python.org/issue45516

bedevere-bot added the docs Documentation in the Doc dir label Oct 22, 2021
FFY00 requested review from brettcannon and jaraco October 22, 2021 21:11
FFY00 force-pushed the bpo-45516-traversableresources-docstring branch from a960d23 to 3df59ff Compare October 22, 2021 21:12

FFY00 commented Oct 22, 2021

Copy link
Copy Markdown
Member Author

@layday do you have any suggestions?

Signed-off-by: Filipe Laíns <lains@riseup.net>
FFY00 force-pushed the bpo-45516-traversableresources-docstring branch from 3df59ff to a9815ee Compare October 22, 2021 21:14

layday commented Oct 23, 2021 •
edited
Loading

Copy link
Copy Markdown

I'd reword this completely - it's far too verbose and fails to get the message across:

    An abstract base class implementing :class:`importlib.abc.ResourceReader`
    for :class:`importlib.abc.Traversable` objects, and defining one
    abstract method, :meth:`files`, which must return such an object.
    Loaders are expected to implement this ABC for resource reading,
    instead of implementing :class:`importlib.abc.ResourceReader` directly,
    to interface with :meth:`importlib.resources.files`.

Document the files method:

.. abstractmethod:: files()

   An abstract method to return a :class:`importlib.abc.Traversable`
   instance for the package's resources.

Drag the ResourceReader section down underneath Traversable and remove the "superseded by" blurb from ResourceReader. The ResourceReader's description might also need adjusting.

brettcannon removed their request for review November 16, 2021 19:37

Copy link
Copy Markdown
Member

https://bugs.python.org/issue45516 is closed. What is the status of this PR?

FFY00 commented Apr 11, 2022

Copy link
Copy Markdown
Member Author

Hi @iritkatriel, it is still relevant, but I am not sure if I will pick this up again soon.

Copy link
Copy Markdown
Member

Ok, I reopened the issue on GitHub.

StanFromIreland changed the title bpo-45516: improve TraversableResources's documentation gh-89679: improve TraversableResources's documentation Jul 28, 2025

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

github-actions Bot added the stale Stale PR or inactive for long period of time. label Apr 10, 2026
ambv requested a review from warsaw as a code owner October 22, 2026 21:34
bedevere-app Bot added the type-feature A feature request or enhancement label Oct 22, 2026

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #35337793 | 📁 Comparing f4397cf against main (5b55b50)

  🔍 Preview build  

2 files changed
± library/importlib.resources.abc.html
± whatsnew/changelog.html

github-actions Bot removed the stale Stale PR or inactive for long period of time. label Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting review docs Documentation in the Doc dir type-feature A feature request or enhancement

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

7 participants


Back | FazBrowse Home | New Git URL