at 24.11-pre 968 B view raw
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 fetchPypi, 6 rustPlatform, 7 cargo, 8 rustc, 9 libiconv, 10 pytestCheckHook, 11}: 12 13buildPythonPackage rec { 14 pname = "y-py"; 15 version = "0.6.2"; 16 format = "pyproject"; 17 18 src = fetchPypi { 19 pname = "y_py"; 20 inherit version; 21 hash = "sha256-R1eoKlBAags6MzqgEiAZozG9bxbkn+1n3KQj+Siz/U0="; 22 }; 23 24 cargoDeps = rustPlatform.fetchCargoTarball { 25 inherit src; 26 name = "${pname}-${version}"; 27 hash = "sha256-RXwrDSPU0wiprsUJwoDzti14H/+bSwy4hK4tYhNVfYw="; 28 }; 29 30 nativeBuildInputs = [ 31 rustPlatform.cargoSetupHook 32 rustPlatform.maturinBuildHook 33 cargo 34 rustc 35 ]; 36 37 buildInputs = lib.optional stdenv.isDarwin libiconv; 38 39 pythonImportsCheck = [ "y_py" ]; 40 41 nativeCheckInputs = [ pytestCheckHook ]; 42 43 meta = { 44 description = "Python bindings for Y-CRDT"; 45 homepage = "https://github.com/y-crdt/ypy"; 46 license = lib.licenses.mit; 47 maintainers = with lib.maintainers; [ dotlambda ]; 48 }; 49}