at master 1.4 kB view raw
1{ 2 lib, 3 fetchFromGitHub, 4 buildPythonPackage, 5 setuptools, 6 # dependencies 7 eth-typing, 8 eth-utils, 9 # nativeCheckInputs 10 asn1tools, 11 factory-boy, 12 hypothesis, 13 pyasn1, 14 pytestCheckHook, 15 coincurve, 16 eth-hash, 17 isPyPy, 18 pydantic, 19}: 20 21buildPythonPackage rec { 22 pname = "eth-keys"; 23 version = "0.7.0"; 24 pyproject = true; 25 26 src = fetchFromGitHub { 27 owner = "ethereum"; 28 repo = "eth-keys"; 29 tag = "v${version}"; 30 hash = "sha256-H/s/D4f4tqP/WTil9uLmFw2Do9sEjMWwEreQEooeszQ="; 31 }; 32 33 build-system = [ setuptools ]; 34 35 dependencies = [ 36 eth-typing 37 eth-utils 38 ]; 39 40 nativeCheckInputs = [ 41 asn1tools 42 factory-boy 43 hypothesis 44 pyasn1 45 pytestCheckHook 46 pydantic 47 ] 48 ++ optional-dependencies.coincurve 49 ++ lib.optional (!isPyPy) eth-hash.optional-dependencies.pysha3 50 ++ lib.optional isPyPy eth-hash.optional-dependencies.pycryptodome; 51 52 pythonImportsCheck = [ "eth_keys" ]; 53 54 disabledTests = [ "test_install_local_wheel" ]; 55 56 optional-dependencies = { 57 coincurve = [ coincurve ]; 58 }; 59 60 meta = { 61 description = "Common API for Ethereum key operations"; 62 homepage = "https://github.com/ethereum/eth-keys"; 63 changelog = "https://github.com/ethereum/eth-keys/blob/v${version}/CHANGELOG.rst"; 64 license = lib.licenses.mit; 65 maintainers = with lib.maintainers; [ hellwolf ]; 66 }; 67}