Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PEP 694: Updates #3997

Merged
merged 14 commits into from
Jan 6, 2025
Merged

PEP 694: Updates #3997

merged 14 commits into from
Jan 6, 2025

Conversation

warsaw
Copy link
Member

@warsaw warsaw commented Sep 25, 2024

Based on discussions rooted here in DPO and other places, this is a major update to PEP 694, Upload 2.0 API for Python Package Repositories.

Changes include:

  • Formatting and phrasing
  • Added myself as a co-author (though I don't want to step on @dstufft 's toes so I'm happy to revert this)
  • Proposed the root URL for PyPI to be https://upload.pypi.org/2.0 although we may want a provisional root URL while the implementation is still in its experimental phase.
  • Added an nonce string to the session creation request JSON, which allows clients to decide whether staged previews are easily guessable or not.
  • In the session creation response JSON, rename the draft subkey of the urls key to stage.
  • In the session creation response JSON, add status and cancel subkeys to the urls key.
  • Describe the expected behavior when this API is used for the first upload of a project.
  • Fix the chunked upload header examples, and provide examples for both the first and second chunk upload.
  • Describe how to replace a partially or fully uploaded file in a staged release before the stage is published.
  • Describe that it is an error to publish a stage that has no files uploaded to it.
  • Elaborate on how the session token is calculated from the hash of the project name, version, and optional nonce.
  • Elaborate on how staged previews can work; make this optional for indexes to support.

@warsaw warsaw requested a review from dstufft as a code owner September 25, 2024 23:32
@hugovk hugovk changed the title Updates to PEP 694 PEP 694: Updates Sep 26, 2024
@warsaw warsaw requested a review from a team as a code owner December 13, 2024 02:05
@warsaw
Copy link
Member Author

warsaw commented Jan 6, 2025

I haven't received any reviews in weeks and I want to restart the discussions, so I'm self-merging. Feel free to revert if you want!

@warsaw warsaw merged commit d1c8ef7 into python:main Jan 6, 2025
5 checks passed
@warsaw warsaw deleted the warsaw/pep-694-updates branch January 7, 2025 00:19
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