pyrevolve: init at 2.2

main
Átila Saraiva 2 years ago
parent 13dc1f09ad
commit fa6e7039b7
  1. 41
      pkgs/development/python-modules/pyrevolve/default.nix
  2. 2
      pkgs/top-level/python-packages.nix

@ -0,0 +1,41 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, contexttimer
, versioneer
, cython
, numpy
, pytest
}:
buildPythonPackage rec {
pname = "pyrevolve";
version = "2.2";
src = fetchFromGitHub {
owner = "devitocodes";
repo = pname;
rev = "v${version}";
sha256 = "sha256-5a4zvyf2vfz8aI6vFMI2vxekYrcUi/YuPFvZnUOx+Zs=";
};
nativeBuildInputs = [ versioneer cython ];
propagatedBuildInputs = [ contexttimer ];
checkInputs = [ pytest numpy ];
# Using approach bellow bcs the tests fail with the pytestCheckHook, throwing the following error
# ImportError: cannot import name 'crevolve' from partially initialized module 'pyrevolve'
# (most likely due to a circular import)
checkPhase = ''
pytest
'';
pythonImportsCheck = [ "pyrevolve" ];
meta = with lib; {
homepage = "https://github.com/devitocodes/pyrevolve";
description = "Python library to manage checkpointing for adjoints";
license = licenses.epl10;
maintainers = with maintainers; [ atila ];
};
}

@ -6349,6 +6349,8 @@ in {
pypoolstation = callPackage ../development/python-modules/pypoolstation { };
pyrevolve = callPackage ../development/python-modules/pyrevolve { };
pyrfxtrx = callPackage ../development/python-modules/pyrfxtrx { };
pyrogram = callPackage ../development/python-modules/pyrogram { };

Loading…
Cancel
Save