-
-
Notifications
You must be signed in to change notification settings - Fork 275
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
Remove Cargo requirement from prepare_metadata_for_build_wheel? #563
Comments
maturin's
Do you have any example of this? We provide templates how to ship wheels for windows/linux/mac with github actions, so I'd hope just shipping wheels for the three major platforms should be a none-issue. maturin already writes complete source distribution metadata, even though currently tagged as Metadata-Version 2.1. Since PEP 643 is accepted, I've opened #564 to bump the version. Tools performing resolution should then just read |
I see, thanks for the explaination. My interpretation to the issue here is that
A friend of mine asked about this privately, the machine has an obscure dev setup (non-manylinux-compatible, I think). It is definitely an edge case. If Cargo is too beneficial to drop, it is definitely reasonable to ask users to install it instead. Fortunately that’s not a big hurdle either, thanks to rustup. |
One thought: Would it be possible to run |
Currently
prepare_metadata_for_build_wheel
would check Cargo’s existence before generating metadata, and persuambly also needs Cargo during the process, but I’m unsure why that is the case—Admittedly I did not read the source and maybe there is a valid reason. But from my naive understanding, the Python package’s metadata can be retrieved entirely by parsingpyproject.toml
andCargo.toml
manually, and should not require Cargo (since anything that’s too complicated to parse without Cargo are Rust-specific from what I can tell). What am I missing here?Removing the dependency on Cargo during metadata-generation would be beneficial for tools that perform dependency resolution (locking) and package installation separately, like Pipenv and Poetry. Currently a lock file must be generated on a platform with compatible wheels published, or have Cargo installed. This means that if a project does not publish (say) wheels for Mac, a user must install Cargo for the locking phase, even if they never intend to build the project locally (since the installation happens elsewhere, e.g. on the server or in a Docker container running Linux).
The text was updated successfully, but these errors were encountered: