-
Notifications
You must be signed in to change notification settings - Fork 933
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
RFC: Clarify that the direct_url.json url field must be a spec-compliant url #1506
Conversation
@konstin thanks for this! Could you also announce this PR on discuss.python.org/packaging. Since this could be considered a spec change, it is worth announcing broadly (I personally don't think this change requires a PEP, but better check). |
|
I wonder if this is too restricted regarding to git urls. If I understand correctly, you can't just convert a scp-like url to a valid url, cf servo/rust-url#220 and linked issues for example. If you can't convert it what should an installer that supports scp-like urls write into |
Wouldn't prefixing them with |
I assume for github they are equivalent, but if this statement is correct they are not always equivalent:
(from https://secure.phabricator.com/T11004) I have no idea how common that is. Maybe, that's just an edge case that can be neglected? |
FYI: We decided to do the normalization in Poetry for now even if it might not always be equivalent in theory. |
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as outdated.
This comment was marked as outdated.
@konstin Could you rebase? |
…ant url Clarify that the `url` field in `direct_url.json` must be a valid url.
Co-authored-by: Stéphane Bidoul <stephane.bidoul@acsone.eu>
50b66cd
to
bba8492
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By the way, this document seems to fix the order of fields in the data structure, but I think that is misleading? At least I have seen valid direct_url.json
files where it has been swapped.
Co-authored-by: chrysle <fritzihab@posteo.de>
Thank you! |
Clarify that the
url
field indirect_url.json
must be a valid url. This was prompted by a case where theurl
field contained a value that was not a url (astral-sh/uv#1744). I'm not sure what the best venue to discuss this change is, so i'm putting it up as a PR here.Relatedly, would it make sense to write a json schem for direct_url.json? A machine readable spec would allow tooling to generate types and would simplify verification.
Post on discuss.python.org
Closes #1510 (link check fix)
Thanks to whoever set up nox + sphinx-autobuild,
nox -s preview
is great!📚 Documentation preview 📚: https://python-packaging-user-guide--1506.org.readthedocs.build/en/1506/