1{ stdenv, buildPythonPackage, fetchFromGitHub 2, future, six, ecdsa, pycryptodome, pytest, cryptography 3}: 4 5buildPythonPackage rec { 6 pname = "python-jose"; 7 version = "2.0.2"; 8 9 # no tests in PyPI tarball 10 src = fetchFromGitHub { 11 owner = "mpdavis"; 12 repo = "python-jose"; 13 # 2.0.2 not tagged on GitHub 14 # see https://github.com/mpdavis/python-jose/issues/86 15 rev = "28cc6719eceb89129eed59c25f7bdac015665bdd"; 16 sha256 = "03wkq2rszy0rzy5gygsh4s7i6ls8zflgbcvxnflvmh7nis7002fp"; 17 }; 18 19 checkInputs = [ 20 pytest 21 cryptography # optional dependency, but needed in tests 22 ]; 23 checkPhase = '' 24 py.test 25 ''; 26 27 propagatedBuildInputs = [ future six ecdsa pycryptodome ]; 28 29 meta = with stdenv.lib; { 30 homepage = https://github.com/mpdavis/python-jose; 31 description = "A JOSE implementation in Python"; 32 license = licenses.mit; 33 maintainers = [ maintainers.jhhuh ]; 34 }; 35}