Skip to content

uv publish cannot find index when configured as explicit=true #9919

@CarrotManMatt

Description

@CarrotManMatt

A pyproject.toml that creates this issue is as follows:

[build-system]
build-backend = "hatchling.build"
requires = ["hatchling"]

[project]
name= "My-Test-Project"
version = "0.1.0"

[tool.uv]
trusted-publishing = "always"

[[tool.uv.index]]
explicit = true
name = "testpypi"
publish-url = "https://test.pypi.org/legacy"
url = "https://test.pypi.org/simple"

Running uv publish --index testpypi results in the following message:

warning: `uv publish` is experimental and may change without warning
error: No indexes were found, can't use index: `testpypi`

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions