Polars
is a data frame library for Rust and Python built on top of Apache Arrow.
The package uses PyO3
to implement Python modules in Rust, and maturin
(which belongs to the PyO3 project) to build.
It has a broken package in nixpkgs.
I am trying to fix it.
I’m stuck on the following error
🍹 Building a mixed python/rust project
💥 maturin failed
Caused by: Cargo metadata failed. Does your crate compile with `cargo build`?
Caused by: `cargo metadata` exited with an error: Updating git repository `https://github.com/messense/cmake-rs.git`
error: failed to load source for dependency `cmake`
Caused by:
Unable to update https://github.com/messense/cmake-rs.git?branch=cross-compile#15ab68ba
Caused by:
failed to clone into: /build/git/db/cmake-rs-1a1c3c7fd02f9517
Caused by:
attempting to update a git repository, but --frozen was specified
Which seems to be related to this part of Cargo.toml
:
[patch.crates-io]
cmake = { git = "https://github.com/messense/cmake-rs.git", branch = "cross-compile" }
A manual cargo build
does succeed locally.
Is the error caused by the sandboxing which disallows network access? If so, I see that rustPlatform has features such as fetchCargoTarball
and importCargoLock
for getting around these sorts of problems, but I do not see anything that could be applied to this particular case.
Or am I coming up against something like this 3-year-old open (and almost completely ignored) nixpkgs
issue?