about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/eth-keyfile
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2022-12-06 19:57:55 +0000
committerAlyssa Ross <hi@alyssa.is>2023-02-08 13:48:30 +0000
commitbf3aadfdd39aa197e18bade671fab6726349ffa4 (patch)
tree698567af766ed441d757b57a7b21e68d4a342a2b /nixpkgs/pkgs/development/python-modules/eth-keyfile
parentf4afc5a01d9539ce09e47494e679c51f80723d07 (diff)
parent99665eb45f58d959d2cb9e49ddb960c79d596f33 (diff)
downloadnixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar
nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.gz
nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.bz2
nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.lz
nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.xz
nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.tar.zst
nixlib-bf3aadfdd39aa197e18bade671fab6726349ffa4.zip
Merge commit '99665eb45f58d959d2cb9e49ddb960c79d596f33'
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/eth-keyfile')
-rw-r--r--nixpkgs/pkgs/development/python-modules/eth-keyfile/default.nix47
1 files changed, 47 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/eth-keyfile/default.nix b/nixpkgs/pkgs/development/python-modules/eth-keyfile/default.nix
new file mode 100644
index 000000000000..fd62501b81d2
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/eth-keyfile/default.nix
@@ -0,0 +1,47 @@
+{ lib
+, buildPythonPackage
+, fetchFromGitHub
+, eth-keys
+, eth-utils
+, pycryptodome
+, pytestCheckHook
+, pythonOlder
+}:
+
+buildPythonPackage rec {
+  pname = "eth-keyfile";
+  version = "0.6.0";
+  disabled = pythonOlder "3.7";
+
+  src = fetchFromGitHub {
+    owner = "ethereum";
+    repo = "eth-keyfile";
+    rev = "v${version}";
+    fetchSubmodules = true;
+    sha256 = "sha256-JD4bRoD9L0JXcd+bTZrq/BkWw5QGzOi1RvoyLJC77kk=";
+  };
+
+  postPatch = ''
+    substituteInPlace setup.py \
+      --replace "'setuptools-markdown'" ""
+  '';
+
+  propagatedBuildInputs = [
+    eth-keys
+    eth-utils
+    pycryptodome
+  ];
+
+  checkInputs = [
+    pytestCheckHook
+  ];
+
+  pythonImportsCheck = [ "eth_keyfile" ];
+
+  meta = with lib; {
+    description = "Tools for handling the encrypted keyfile format used to store private keys";
+    homepage = "https://github.com/ethereum/eth-keyfile";
+    license = licenses.mit;
+    maintainers = with maintainers; [ SuperSandro2000 ];
+  };
+}