-
Notifications
You must be signed in to change notification settings - Fork 980
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
Support PEP 625 (Filename of a Source Distribution) #12245
Comments
This is likely blocked on pypa/packaging#527. |
This is probably also blocked on finding a good migration path that isn't too obtrusive for users. Right now, there are a lot of files being uploaded that would fail to upload once this change is implemented, and IMO this would break too many users for us to enable this right now:
I think a good migration path would be:
|
The other thing we could do, is forcibly normalize ourselves, though we hadn't done that in the past and I know that would break at least twine's checks if a file has been uploaded already. |
Blocked on #14156 as well. |
Until the version in the sdist filename is verified as described in this issue, it's possible to create multiple sdists per release (as seen from the filename point of view). Example: upload This does not seem to be in the spirit of PEP 527:
|
Probably also blocked on pypa/setuptools#3593 as the predominant builder of source distributions. |
There doesn't seem to be any real progress here towards builders producing normalized source distribution filenames:
|
pypa/setuptools#3593 has been closed (implemented) for a little while now, would be interesting to see if it is yet making a dent in that graph |
PR to start warning uploaders of non-PEP 625 compliant filenames is here: #17110 |
Hi, This change is creating some confusion in the Django project (unsurprisingly, considering the non-standard capitalization of our package and build files historically), especially around the timeline and extent of the deprecation: https://code.djangoproject.com/ticket/35980. Could you clarify what you meant in the comment above with "[...] probably by EOY we could fully support PEP 625."? Does that mean that non-pep625 build files could start being rejected, or is that just a prediction about the progress towards the goal of all newly uploaded build files being pep625-compliant? The warning email from PyPI that Django received with our latest release also mentions that "In the future, PyPI will require all newly uploaded source distribution filenames to comply with PEP 625.". Is there a clearer timeline for this? Will there be a mechanism where maintainers will be given advance notice of that change, or is there a specific GH issue one could subscribe to for example? Thanks for all the work you do on PyPI, we're big fans 🎉 |
Hi @bmispelon, thanks for your comment here, sorry this is causing confusion for the Django project.
By "fully support PEP 625" I meant that PyPI would be in compliance with PEP 625, and reject uploads of filenames that are invalid per PEP 625. I think it's unlikely that we actually will do this by EOY, though.
We don't currently have a timeline other than "eventually". If it's helpful, I can commit to having the warning emails include a clear deadline at a minimum of 6 months before said deadline, and share that deadline on this issue as well. Would that suffice? That also means this wouldn't be enforced before Django's release in April. FWIW, I think this change should be unnecessary -- the actual project name shouldn't need to change, just the underlying build tooling that is producing the source distribution. In this case, upgrading |
To add more context to this, the project name is used in different places with different normalizations: There is the human-readable name, and there is the dist-info name (
Afaik the only blocker here is pypa/setuptools#3777 |
I do not think that even pypa/setuptools#3777 is a blocker here, though it might take a slightly pedantic reading to agree with this. As I understand it, this issue is specifically about PEP 625 and source distribution names: so though it seems to be true that setuptools is producing wheels whose naming is not PEP-491 compliant - that would be out of scope. There probably should be an analogous issue here for wheels: "support [enforce] PEP491". But I think that is not what this issue says, and I guess it is unlikely that warehouse would insist on PEP-491 while setuptools produces non-compliant wheels. |
Hi! This is Natalia, one of the current Django Fellows. Thank you David for your feedback! For Django, the release process uses a unified workflow that relies on As a workaround, we’ve been pinning |
Ah, then I guess pypa/setuptools#3777 is a blocker specifically for django - but still not, strictly speaking, a blocker here... setuptools sounds open to pull requests fixing this and I assume that it must be not very difficult once the relevant bit of code is identified, perhaps you are motivated to make that happen. |
Ish :-) I believe this inconsistency (which goes beyond just name casing) could affect more packages than just Django, for similar reasons. It’s problematic and likely complicates tooling to have release artifacts with varying casing or punctuation.
👍 |
What's the problem this feature will solve?
PEP 625 has been accepted, PyPI should be updated to support the PEP.
Describe the solution you'd like
PyPI needs to implement some changes to support the PEP:
The text was updated successfully, but these errors were encountered: