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

Paths to using published versions of vendored, forked crates? #5588

Closed
musicinmybrain opened this issue Jul 30, 2024 · 5 comments
Closed

Paths to using published versions of vendored, forked crates? #5588

musicinmybrain opened this issue Jul 30, 2024 · 5 comments
Labels
internal A refactor or improvement that is not user-facing question Asking for clarification or support

Comments

@musicinmybrain
Copy link
Contributor

While finishing up a uv package for Fedora Linux, I’ve documented several cases where third-party crates have been copied into uv.

(Please correct me if any of the above is not quite right.)

Fedora policy requires me to ask if there is a path toward eventually using a system copy of any or all of these libraries, i.e., if the necessary changes may eventually be worked around or upstreamed in the original crates.io packages.

@musicinmybrain
Copy link
Contributor Author

I also found that crates/uv-python/python/packaging is vendored from https://pypi.org/project/packaging, but the fact that uv does not necessarily depend on a Python interpreter or environment provides much of the explanation for why this is necessary, and the commit message for 7964bfb seems to provide most of the remaining rationale.

A similar rationale seems to apply for crates/uv-virtualenv/src/activator/, bundled and slightly forked from files in https://pypi.org/project/virtualenv and specificially https://github.com/pypa/virtualenv/tree/main/src/virtualenv/activation.

@musicinmybrain
Copy link
Contributor Author

Regarding forked crates that are not directly vendored, but referenced by git dependencies:

@konstin
Copy link
Member

konstin commented Jul 30, 2024

crates/pep440-rs is forked from version 0.6.0 of https://crates.io/crates/pep440_rs which is maintained in https://github.com/konstin/pep440-rs
crates/pep508-rs is forked from version 0.6.0 of https://crates.io/crates/pep508_rs which is maintained in https://github.com/konstin/pep508_rs
crates/uv-virtualenv/ as a whole is derived from https://github.com/konstin/gourgeist 0.0.4, which was published as https://crates.io/crates/gourgeist. I am inclined not to treat this as a case of bundling, because it looks like the project was subsumed into uv, and the link to uv at https://konstin.github.io/gourgeist/ seems to support this.

These have diverged significantly and the upstream versions are only passively maintained, uv requires these custom versions and can't use a system copy.

@charliermarsh charliermarsh added question Asking for clarification or support internal A refactor or improvement that is not user-facing labels Jul 30, 2024
@zanieb
Copy link
Member

zanieb commented Oct 21, 2024

Are there remaining open questions here?

@musicinmybrain
Copy link
Contributor Author

musicinmybrain commented Oct 21, 2024

I think this is adequately answered – thanks!

(I’m also tracking the forked tl crate, #6687, but that’s just waiting on tl upstream to become active again and consider y21/tl#69.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal A refactor or improvement that is not user-facing question Asking for clarification or support
Projects
None yet
Development

No branches or pull requests

4 participants