Skip to content

[feature request] Support for explicit source/index specification on individual dependencies #6582

@menzenski

Description

@menzenski

We currently use a mix of pyenv, pipx, and Poetry in our Python projects and I'm very interested in uv's potential to replace all of these tools.

One of the things that we want to be able to do is to use the public PyPI index by default, but use our internal Artifactory index for specific organization-internal dependencies. We don't want to search the public PyPI index for those private dependencies in case there's a public one with the same name, and we don't want everything to go through our Artifactory index because of the impact on cost from the data transfer.

With Poetry, we can do this via explicit sources - is there a way to accomplish the same sort of behavior with uv?

For example, our pyproject.toml file would include this configuration:

[tool.poetry.dependencies]
python = ">=3.11,<3.12"
my-private-package = {version = "^0.12.0", source = "private_artifactory"}
rich = "^13.7.1"

[[tool.poetry.source]]
name = "PyPI"
priority = "primary"

[[tool.poetry.source]]
name = "private_artifactory"
url = "https://<organization host>/artifactory/api/pypi/pypi/simple"
priority = "explicit"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions