Skip to content

Correctly handle pending publishers when a project is created w/o trusted publishing #18478

@stefanvanburen

Description

@stefanvanburen

Describe the bug

Publishing existing package with newly set up trusted publishing failed with invalid-pending-publisher: valid token, but project already exists.

Expected behavior

It should publish without failure.

To Reproduce

https://github.com/bufbuild/protovalidate-python/actions/runs/16729274056/job/47353099459#step:4:140

My Platform

Additional context

We've had protovalidate-python publishing via the release.yaml workflow since the beginning of the project, and just set up trusted publishing following this guide. Specifically, this commit. The owner on the PyPI side is set up with a trusted publisher that is pretty straightforward, and matches the repo/workflow/environment on the GitHub side:

Image

I've triple checked that everything is matching up on the GH / PyPI side, but I'm wondering if the pending publisher is something on the PyPI DB side that needs to be cleaned up?

The error looks somewhat similar to #14389, but different enough that I'm not sure it's related.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions