1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
|
{ lib
, buildPythonPackage
, fetchFromGitHub
, aiohttp
, eth-abi
, eth-account
, eth-hash
, eth-typing
, eth-utils
, eth-rlp
, hexbytes
, ipfshttpclient
, jsonschema
, lru-dict
, protobuf
, requests
, typing-extensions
, websockets
# , eth-tester
# , py-geth
, pytestCheckHook
, pythonOlder
, pythonRelaxDepsHook
}:
buildPythonPackage rec {
pname = "web3";
version = "5.31.1";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "ethereum";
repo = "web3.py";
rev = "v${version}";
hash = "sha256-YsAbPI9Y6z+snKZ9NsA0YSpB38n+ra4+Ei6COYFe8v4=";
};
nativeBuildInputs = [
pythonRelaxDepsHook
];
propagatedBuildInputs = [
aiohttp
eth-abi
eth-account
eth-hash
eth-rlp
eth-typing
eth-utils
hexbytes
ipfshttpclient
jsonschema
lru-dict
protobuf
requests
websockets
] ++ lib.optionals (pythonOlder "3.8") [
typing-extensions
] ++ eth-hash.optional-dependencies.pycryptodome;
pythonRelaxDeps = true;
# TODO: package eth-tester
#checkInputs = [
# eth-tester
# eth-tester.optional-dependencies.py-evm
# py-geth
# pytestCheckHook
#];
doCheck = false;
pythonImportsCheck = [
"web3"
];
meta = with lib; {
description = "Web3 library for interactions";
homepage = "https://github.com/ethereum/web3";
license = licenses.mit;
maintainers = with maintainers; [ raitobezarius ];
};
}
|