3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/python-modules/tenacity/default.nix

34 lines
891 B
Nix
Raw Normal View History

{ lib, buildPythonPackage, fetchPypi, isPy27, isPy3k
, pbr, six, futures, monotonic, typing, setuptools_scm
, pytest, sphinx, tornado, typeguard
2019-01-10 17:14:54 +00:00
}:
buildPythonPackage rec {
pname = "tenacity";
version = "6.2.0";
2019-01-10 17:14:54 +00:00
src = fetchPypi {
inherit pname version;
sha256 = "16ikf6n6dw1kzncs6vjc4iccl76f9arln59jhiiai27lzbkr1bi9";
2019-01-10 17:14:54 +00:00
};
2019-10-24 07:47:50 +01:00
nativeBuildInputs = [ pbr setuptools_scm ];
2019-01-10 17:14:54 +00:00
propagatedBuildInputs = [ six ]
++ lib.optionals isPy27 [ futures monotonic typing ];
2019-01-10 17:14:54 +00:00
checkInputs = [ pytest sphinx tornado ]
++ lib.optionals isPy3k [ typeguard ];
2019-10-24 07:47:50 +01:00
checkPhase = if isPy27 then ''
2019-01-10 17:14:54 +00:00
pytest --ignore='tenacity/tests/test_asyncio.py'
'' else ''
pytest
'';
meta = with lib; {
homepage = "https://github.com/jd/tenacity";
2019-01-10 17:14:54 +00:00
description = "Retrying library for Python";
license = licenses.asl20;
maintainers = with maintainers; [ jakewaksbaum ];
};
}