diff --git a/pkgs/development/python-modules/keepkey/default.nix b/pkgs/development/python-modules/keepkey/default.nix new file mode 100644 index 000000000000..0d7f7661e7dd --- /dev/null +++ b/pkgs/development/python-modules/keepkey/default.nix @@ -0,0 +1,30 @@ +{ stdenv, fetchPypi, buildPythonPackage, ecdsa +, mnemonic, protobuf3_0, hidapi }: + +buildPythonPackage rec { + name = "${pname}-${version}"; + pname = "keepkey"; + version = "0.7.3"; + + src = fetchPypi { + inherit pname version; + sha256 = "14d2r8dlx997ypgma2k8by90acw7i3l7hfq4gar9lcka0lqfj714"; + }; + + propagatedBuildInputs = [ protobuf3_0 hidapi ]; + + buildInputs = [ ecdsa mnemonic ]; + + # There are no actual tests: "ImportError: No module named tests" + doCheck = false; + + # Remove impossible dependency constraint + postPatch = "sed -i -e 's|hidapi==|hidapi>=|' setup.py"; + + meta = with stdenv.lib; { + description = "KeepKey Python client"; + homepage = https://github.com/keepkey/python-keepkey; + license = licenses.gpl3; + maintainers = with maintainers; [ np ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index f832beea6747..ab3a8a28a979 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -29632,36 +29632,14 @@ EOF mnemonic = callPackage ../development/python-modules/mnemonic.nix { }; + keepkey = callPackage ../development/python-modules/keepkey { }; + ledgerblue = callPackage ../development/python-modules/ledgerblue { }; ecpy = callPackage ../development/python-modules/ecpy { }; trezor = callPackage ../development/python-modules/trezor.nix { }; - keepkey = buildPythonPackage rec{ - version = "0.7.3"; - name = "keepkey-${version}"; - - src = pkgs.fetchurl { - url = "mirror://pypi/k/keepkey/${name}.tar.gz"; - sha256 = "14d2r8dlx997ypgma2k8by90acw7i3l7hfq4gar9lcka0lqfj714"; - }; - - propagatedBuildInputs = with self; [ protobuf3_0 hidapi ]; - - buildInputs = with self; [ ecdsa mnemonic ]; - - # There are no actual tests: "ImportError: No module named tests" - doCheck = false; - - meta = { - description = "KeepKey Python client"; - homepage = https://github.com/keepkey/python-keepkey; - license = licenses.gpl3; - maintainers = with maintainers; [ np ]; - }; - }; - semver = buildPythonPackage rec { name = "semver-${version}"; version = "2.2.1";