Skip to content

Use dependency groups (PEP 735) - #15366

Open
mwtoews wants to merge 1 commit into
ipython:mainfrom
mwtoews:pep-735
Open

Use dependency groups (PEP 735)#15366
mwtoews wants to merge 1 commit into
ipython:mainfrom
mwtoews:pep-735

Conversation

@mwtoews

@mwtoews mwtoews commented Aug 12, 2026

Copy link
Copy Markdown

This PR moves some dependency lists from project.optional-dependencies (aka "extras") to dependency-groups, as described by PEP 735. Some details:

  • Keep black, matplotlib and all as "extras" intended for end-users
  • Move docs (renamed from doc), test, and test_extra to dependency groups, intended for developers
    • Note that pip install --dryrun ipython[test] will show a warning that the package does not have an extra named test.
    • Developers that need this dependency will require pip v25.1 (2025-04-26) (or uv) and use the --group test option
  • Add a build group with tools needed to build this package
  • Add a dev group, which adds pre-commit and the build and test groups; uv enables this group by default.
  • Merge docs/requirements.txt into the docs group, and remove this file, as it is unnecessary duplication
  • Rewrite a few "uv pip install" commands into one line, as it often works best to solve a larger group of dependencies at once

git clone https://github.com/ipython/ipykernel
cd ipykernel
pip install -e .[test]
pip install -e . --group test

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant