Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / rchitect / default.nix
blobcbafc0d2b2b6d46befb317d111f6884a645772fd
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , cffi
5 , pytestCheckHook
6 , pytest-mock
7 , pythonOlder
8 , R
9 , rPackages
10 , six
11 , packaging
14 buildPythonPackage rec {
15   pname = "rchitect";
16   version = "0.4.6";
17   format = "setuptools";
19   disabled = pythonOlder "3.7";
21   src = fetchFromGitHub {
22     owner = "randy3k";
23     repo = pname;
24     rev = "refs/tags/v${version}";
25     hash = "sha256-IVyYzf433m03RRfL5SmUOdaXFy0NHf/QuAdtUeUjIz0=";
26   };
28   postPatch = ''
29     substituteInPlace setup.py \
30       --replace '"pytest-runner"' ""
31   '';
33   propagatedBuildInputs = [
34     cffi
35     six
36     packaging
37   ] ++ (with rPackages; [
38     reticulate
39   ]);
41   nativeCheckInputs = [
42     pytestCheckHook
43     pytest-mock
44     R
45   ];
47   preCheck = ''
48     export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${R}/lib/R/lib
49     cd $TMPDIR
50   '';
52   pythonImportsCheck = [ "rchitect" ];
54   meta = with lib; {
55     description = "Interoperate R with Python";
56     homepage = "https://github.com/randy3k/rchitect";
57     changelog = "https://github.com/randy3k/rchitect/blob/v${version}/CHANGELOG.md";
58     license = licenses.mit;
59     maintainers = with maintainers; [ savyajha ];
60   };