Skip to content

📝 docs(api): add :param: descriptions to all public APIs#32

Merged
gaborbernat merged 1 commit intotox-dev:mainfrom
gaborbernat:30
Feb 26, 2026
Merged

📝 docs(api): add :param: descriptions to all public APIs#32
gaborbernat merged 1 commit intotox-dev:mainfrom
gaborbernat:30

Conversation

@gaborbernat
Copy link
Member

The Sphinx API reference was rendering parameter signatures without descriptions for most public methods and constructors. While sphinx-autodoc-typehints picks up types from annotations, parameter purpose still needs explicit :param: docstrings to appear in the rendered docs.

This adds :param: descriptions to every public method, constructor, and dataclass across PythonInfo, PythonSpec, DiskCache, SimpleVersion, SimpleSpecifier, and SimpleSpecifierSet. Parameters that were already referenced inline with *param* emphasis were expanded to proper Sphinx :param: directives so they render consistently in the API reference.

Hatch monkeypatches `propose_interpreters` to filter out incompatible
interpreters, which broke when virtualenv moved discovery to this
package. Adding a `predicate` callback gives downstream tools a public
API to filter interpreters without monkeypatching internals.

Named `predicate` instead of `filter` to avoid shadowing the Python
builtin (ruff A002).

Closes tox-dev#30
@gaborbernat gaborbernat added the documentation Improvements or additions to documentation label Feb 26, 2026
@gaborbernat gaborbernat merged commit e83d007 into tox-dev:main Feb 26, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant