about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/eth-abi
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-abi
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-abi')
-rw-r--r--nixpkgs/pkgs/development/python-modules/eth-abi/default.nix58
1 files changed, 58 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/eth-abi/default.nix b/nixpkgs/pkgs/development/python-modules/eth-abi/default.nix
new file mode 100644
index 000000000000..7bf0f9b49710
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/eth-abi/default.nix
@@ -0,0 +1,58 @@
+{ lib
+, buildPythonPackage
+, fetchFromGitHub
+, eth-hash
+, eth-typing
+, eth-utils
+, hypothesis
+, parsimonious
+, pytestCheckHook
+, pythonOlder
+}:
+
+buildPythonPackage rec {
+  pname = "eth-abi";
+  version = "3.0.0";
+  disabled = pythonOlder "3.7";
+
+  src = fetchFromGitHub {
+    owner = "ethereum";
+    repo = "eth-abi";
+    rev = "v${version}";
+    sha256 = "sha256-qiuyGVOy+n8l3jSqwMGnBXcDrOxIiJ0lNP4lq/EQEhU=";
+  };
+
+  postPatch = ''
+    substituteInPlace setup.py \
+      --replace "parsimonious>=0.8.0,<0.9.0" "parsimonious"
+  '';
+
+  propagatedBuildInputs = [
+    eth-typing
+    eth-utils
+    parsimonious
+  ];
+
+  checkInputs = [
+    hypothesis
+    pytestCheckHook
+  ] ++ eth-hash.optional-dependencies.pycryptodome;
+
+  disabledTests = [
+    # boolean list representation changed
+    "test_get_abi_strategy_returns_certain_strategies_for_known_type_strings"
+    # hypothesis.errors.Flaky
+    "test_base_equals_has_expected_behavior_for_parsable_types"
+    "test_has_arrlist_has_expected_behavior_for_parsable_types"
+    "test_is_base_tuple_has_expected_behavior_for_parsable_types"
+  ];
+
+  pythonImportsCheck = [ "eth_abi" ];
+
+  meta = with lib; {
+    description = "Ethereum ABI utilities";
+    homepage = "https://github.com/ethereum/eth-abi";
+    license = licenses.mit;
+    maintainers = with maintainers; [ SuperSandro2000 ];
+  };
+}