Implement PEP 735 Dependency Groups#4800
Merged
Bibo-Joshi merged 9 commits intomasterfrom May 24, 2025
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR implements PEP 735 dependency groups, removes legacy requirement files, and updates CI/docs workflows to use pip’s --group installs.
- Define
tests,docs, andalldependency groups inpyproject.toml - Remove
requirements-*.txtfiles and switch workflows from-rinstalls to--groupflags - Reformat array syntax and lint settings in
pyproject.tomlfor consistency
Reviewed Changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| requirements-unit-tests.txt | Removed legacy test requirements file |
| requirements-dev-all.txt | Removed legacy dev-all requirements file |
| pyproject.toml | Added [dependency-groups], collapsed arrays, updated optional-dependencies |
| docs/requirements-docs.txt | Removed legacy docs requirements file |
| .readthedocs.yml | Updated RTD install step—now only pip install . |
| .github/workflows/unit_tests.yml | Switched to pip install . --group tests, removed old installs |
| .github/workflows/test_official.yml | Switched to pip install .[all] --group tests |
| .github/workflows/docs-linkcheck.yml | Switched to pip install .[all] --group all |
| .github/workflows/docs-admonitions.yml | Switched to pip install . --group all |
| .github/workflows/chango.yml | Switched to pip install . --group docs |
| .github/CONTRIBUTING.rst | Updated contributor setup to use --group all |
Comments suppressed due to low confidence (3)
.readthedocs.yml:20
- The ReadTheDocs config no longer installs documentation dependencies. You should add an install argument to include the
docsgroup (e.g.,args: ["--group", "docs"]) so Sphinx requirements are pulled in.
- method: pip
path: .
.github/workflows/unit_tests.yml:41
- [nitpick] The
testsdependency group already includespytest-xdist, so this extra installation is redundant and can be removed.
python -W ignore -m pip install pytest-xdist
.github/workflows/docs-admonitions.yml:34
- With the old requirements files removed, the cache no longer tracks dependency changes. Consider adding
cache-dependency-path: 'pyproject.toml'(or similar) to ensure the cache is invalidated when dependencies are updated.
- cache-dependency-path: '**/requirements*.txt'
Bibo-Joshi
requested changes
May 23, 2025
Member
Bibo-Joshi
left a comment
There was a problem hiding this comment.
Thanks for the PR! Really nice seeing that PEP in action!
2 tasks
Bibo-Joshi
approved these changes
May 24, 2025
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #4795.
Also ran the standard vscode file formatter on pyproject.toml, so if you're wondering about that change, it's that.
Also works with
uv:uv sync --all-extras --all-groups