Skip to content

feat(pypi): add the extras from the pyproject.toml to the hubs with pip.configure - #48

Draft
aignas wants to merge 1 commit into
feat.aignas.extras-edges-06-dependency-group-extrasfrom
feat.aignas.extras-edges-07-configure-extras
Draft

aignas wants to merge 1 commit into
feat.aignas.extras-edges-06-dependency-group-extrasfrom
feat.aignas.extras-edges-07-configure-extras

Conversation

@aignas

@aignas aignas commented Nov 22, 2026

Copy link
Copy Markdown
Owner

The extras that the user depends on directly are often not in the lock
file, e.g. when the requirements are compiled with the extras stripped.
pip.configure now adds the extras requested in the selected
pyproject.toml dependency groups to the hub, so
@pypi//requests:[socks] exists and @pypi//requests includes the
extra. The markers of the requirements are evaluated for each target
platform, so an extra is only added for the platforms that request it,
splitting the config settings where needed.

Part of #41. Based on the previous PR of the stack.

Work towards bazel-contrib#2786

…ip.configure

The extras that the user depends on directly are often not in the lock
file, e.g. when it is compiled with the extras stripped. pip.configure
now adds the extras requested in the selected pyproject.toml dependency
groups, e.g. requests[socks], to the hub, so that the [socks] target
exists and the package target includes the extra. The environment
markers of the requirements are evaluated for each target platform, so
an extra is only added for the platforms that request it.

Work towards bazel-contrib#2786
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