uv/crates/pypi-types/src
Charlie Marsh a2a1b2fb0f
Avoid enforcing URL correctness for installed distributions (#1793)
## Summary

Allows the corresponding `pypi_types` struct to use any URL, since other
installers can put those into the environment, and Poetry seems to write
invalid URLs.

If we see a distribution with an invalid URL, we just treat it as a
registry distribution, which isn't ideal, but is better than (1)
erroring, and (2) changing `Url` to `String` everywhere internally. (I'm
torn on this second option.)

Closes https://github.com/astral-sh/uv/issues/1744.

## Test Plan

- Added `flask = { git = "git@github.com:pallets/flask.git", rev =
"b90a4f1f4a370e92054b9cc9db0efcb864f87ebe" }` to
`scripts/editable-installs/poetry_editable/pyproject.toml`.
- Ran `poetry install`.
- Ran `cargo pip freeze`. Verified that it errored on `main`, but passed
here.
- Ran `cargo run pip install "flask==3.0.0"`. Verified that it
uninstalled the existing Flask, and installed a new version from the
registry.
2024-02-21 09:06:31 -05:00
..
base_url.rs Fix broken URLs parsed from relative paths in registries (#1413) 2024-02-15 22:37:09 -06:00
direct_url.rs Avoid enforcing URL correctness for installed distributions (#1793) 2024-02-21 09:06:31 -05:00
lenient_requirement.rs Add support for `>dev` specifier (#1776) 2024-02-20 20:27:30 +00:00
lib.rs Add support for relative URLs in simple metadata responses (#721) 2023-12-27 08:53:21 -05:00
metadata.rs Ignore invalid extras from PyPI (#1731) 2024-02-19 22:26:29 -05:00
simple_json.rs Support MD5 hashes (#1556) 2024-02-17 00:25:16 +00:00