web3 7.0.0b1__py3-none-any.whl → 7.0.0b3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ens/async_ens.py +6 -8
- ens/ens.py +6 -6
- ens/utils.py +18 -16
- web3/_utils/abi.py +9 -15
- web3/_utils/events.py +15 -6
- web3/_utils/math.py +12 -14
- web3/_utils/method_formatters.py +7 -0
- web3/_utils/module_testing/eth_module.py +67 -6
- web3/_utils/module_testing/module_testing_utils.py +2 -2
- web3/_utils/request.py +1 -1
- web3/_utils/rpc_abi.py +1 -0
- web3/_utils/transactions.py +4 -0
- web3/contract/base_contract.py +1 -1
- web3/datastructures.py +7 -7
- web3/eth/async_eth.py +20 -2
- web3/eth/eth.py +13 -1
- web3/exceptions.py +11 -0
- web3/main.py +4 -30
- web3/manager.py +12 -13
- web3/middleware/__init__.py +9 -8
- web3/module.py +1 -1
- web3/providers/async_base.py +6 -6
- web3/providers/base.py +8 -8
- web3/providers/eth_tester/main.py +16 -20
- web3/providers/ipc.py +1 -1
- web3/providers/legacy_websocket.py +1 -1
- web3/providers/persistent/persistent.py +2 -2
- web3/providers/persistent/request_processor.py +3 -5
- web3/tools/benchmark/main.py +2 -2
- web3/types.py +4 -0
- web3/utils/caching.py +2 -4
- {web3-7.0.0b1.dist-info → web3-7.0.0b3.dist-info}/METADATA +3 -9
- web3-7.0.0b3.dist-info/RECORD +168 -0
- {web3-7.0.0b1.dist-info → web3-7.0.0b3.dist-info}/WHEEL +1 -1
- {web3-7.0.0b1.dist-info → web3-7.0.0b3.dist-info}/top_level.txt +0 -1
- ethpm/__init__.py +0 -20
- ethpm/_utils/__init__.py +0 -0
- ethpm/_utils/backend.py +0 -93
- ethpm/_utils/cache.py +0 -44
- ethpm/_utils/chains.py +0 -119
- ethpm/_utils/contract.py +0 -35
- ethpm/_utils/deployments.py +0 -145
- ethpm/_utils/ipfs.py +0 -116
- ethpm/_utils/protobuf/__init__.py +0 -0
- ethpm/_utils/protobuf/ipfs_file_pb2.py +0 -33
- ethpm/_utils/registry.py +0 -29
- ethpm/assets/__init__.py +0 -0
- ethpm/assets/ens/v3.json +0 -1
- ethpm/assets/escrow/with_bytecode_v3.json +0 -1
- ethpm/assets/ipfs_file.proto +0 -32
- ethpm/assets/owned/output_v3.json +0 -1
- ethpm/assets/owned/with_contract_type_v3.json +0 -1
- ethpm/assets/registry/contracts/Authority.sol +0 -156
- ethpm/assets/registry/contracts/IndexedOrderedSetLib.sol +0 -106
- ethpm/assets/registry/contracts/PackageDB.sol +0 -225
- ethpm/assets/registry/contracts/PackageRegistry.sol +0 -361
- ethpm/assets/registry/contracts/PackageRegistryInterface.sol +0 -97
- ethpm/assets/registry/contracts/ReleaseDB.sol +0 -309
- ethpm/assets/registry/contracts/ReleaseValidator.sol +0 -152
- ethpm/assets/registry/solc_input.json +0 -1
- ethpm/assets/registry/solc_output.json +0 -1
- ethpm/assets/registry/v3.json +0 -1
- ethpm/assets/safe-math-lib/v3-strict-no-deployments.json +0 -1
- ethpm/assets/simple-registry/contracts/Ownable.sol +0 -63
- ethpm/assets/simple-registry/contracts/PackageRegistry.sol +0 -373
- ethpm/assets/simple-registry/contracts/PackageRegistryInterface.sol +0 -96
- ethpm/assets/simple-registry/solc_input.json +0 -33
- ethpm/assets/simple-registry/solc_output.json +0 -1
- ethpm/assets/simple-registry/v3.json +0 -1
- ethpm/assets/standard-token/output_v3.json +0 -1
- ethpm/assets/standard-token/with_bytecode_v3.json +0 -1
- ethpm/assets/vyper_registry/0.1.0.json +0 -1
- ethpm/assets/vyper_registry/registry.vy +0 -216
- ethpm/assets/vyper_registry/registry_with_delete.vy +0 -244
- ethpm/backends/__init__.py +0 -0
- ethpm/backends/base.py +0 -43
- ethpm/backends/http.py +0 -108
- ethpm/backends/ipfs.py +0 -219
- ethpm/backends/registry.py +0 -154
- ethpm/constants.py +0 -17
- ethpm/contract.py +0 -187
- ethpm/dependencies.py +0 -58
- ethpm/deployments.py +0 -80
- ethpm/ethpm-spec/examples/escrow/1.0.0-pretty.json +0 -146
- ethpm/ethpm-spec/examples/escrow/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/escrow/contracts/Escrow.sol +0 -32
- ethpm/ethpm-spec/examples/escrow/contracts/SafeSendLib.sol +0 -20
- ethpm/ethpm-spec/examples/escrow/v3-pretty.json +0 -171
- ethpm/ethpm-spec/examples/escrow/v3.json +0 -1
- ethpm/ethpm-spec/examples/owned/1.0.0-pretty.json +0 -21
- ethpm/ethpm-spec/examples/owned/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/owned/contracts/Owned.sol +0 -12
- ethpm/ethpm-spec/examples/owned/v3-pretty.json +0 -27
- ethpm/ethpm-spec/examples/owned/v3.json +0 -1
- ethpm/ethpm-spec/examples/piper-coin/1.0.0-pretty.json +0 -31
- ethpm/ethpm-spec/examples/piper-coin/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/piper-coin/v3-pretty.json +0 -21
- ethpm/ethpm-spec/examples/piper-coin/v3.json +0 -1
- ethpm/ethpm-spec/examples/safe-math-lib/1.0.0-pretty.json +0 -85
- ethpm/ethpm-spec/examples/safe-math-lib/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/safe-math-lib/contracts/SafeMathLib.sol +0 -24
- ethpm/ethpm-spec/examples/safe-math-lib/v3-pretty.json +0 -117
- ethpm/ethpm-spec/examples/safe-math-lib/v3.json +0 -1
- ethpm/ethpm-spec/examples/standard-token/1.0.0-pretty.json +0 -55
- ethpm/ethpm-spec/examples/standard-token/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/standard-token/contracts/AbstractToken.sol +0 -20
- ethpm/ethpm-spec/examples/standard-token/contracts/StandardToken.sol +0 -84
- ethpm/ethpm-spec/examples/standard-token/v3-pretty.json +0 -460
- ethpm/ethpm-spec/examples/standard-token/v3.json +0 -1
- ethpm/ethpm-spec/examples/transferable/1.0.0-pretty.json +0 -21
- ethpm/ethpm-spec/examples/transferable/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/transferable/contracts/Transferable.sol +0 -14
- ethpm/ethpm-spec/examples/transferable/v3-pretty.json +0 -27
- ethpm/ethpm-spec/examples/transferable/v3.json +0 -1
- ethpm/ethpm-spec/examples/wallet/1.0.0-pretty.json +0 -120
- ethpm/ethpm-spec/examples/wallet/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/wallet/contracts/Wallet.sol +0 -41
- ethpm/ethpm-spec/examples/wallet/v3-pretty.json +0 -181
- ethpm/ethpm-spec/examples/wallet/v3.json +0 -1
- ethpm/ethpm-spec/examples/wallet-with-send/1.0.0-pretty.json +0 -135
- ethpm/ethpm-spec/examples/wallet-with-send/1.0.0.json +0 -1
- ethpm/ethpm-spec/examples/wallet-with-send/contracts/WalletWithSend.sol +0 -18
- ethpm/ethpm-spec/examples/wallet-with-send/v3-pretty.json +0 -207
- ethpm/ethpm-spec/examples/wallet-with-send/v3.json +0 -1
- ethpm/ethpm-spec/spec/package.spec.json +0 -379
- ethpm/ethpm-spec/spec/v3.spec.json +0 -483
- ethpm/exceptions.py +0 -68
- ethpm/package.py +0 -438
- ethpm/tools/__init__.py +0 -4
- ethpm/tools/builder.py +0 -930
- ethpm/tools/checker.py +0 -312
- ethpm/tools/get_manifest.py +0 -19
- ethpm/uri.py +0 -141
- ethpm/validation/__init__.py +0 -0
- ethpm/validation/manifest.py +0 -146
- ethpm/validation/misc.py +0 -39
- ethpm/validation/package.py +0 -80
- ethpm/validation/uri.py +0 -163
- web3/pm.py +0 -602
- web3/tools/__init__.py +0 -4
- web3/tools/pytest_ethereum/__init__.py +0 -0
- web3/tools/pytest_ethereum/_utils.py +0 -145
- web3/tools/pytest_ethereum/deployer.py +0 -48
- web3/tools/pytest_ethereum/exceptions.py +0 -22
- web3/tools/pytest_ethereum/linker.py +0 -128
- web3/tools/pytest_ethereum/plugins.py +0 -33
- web3-7.0.0b1.dist-info/RECORD +0 -280
- web3-7.0.0b1.dist-info/entry_points.txt +0 -2
- {web3-7.0.0b1.dist-info → web3-7.0.0b3.dist-info}/LICENSE +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: web3
|
|
3
|
-
Version: 7.0.
|
|
3
|
+
Version: 7.0.0b3
|
|
4
4
|
Summary: web3.py
|
|
5
5
|
Home-page: https://github.com/ethereum/web3.py
|
|
6
6
|
Author: The Ethereum Foundation
|
|
@@ -26,8 +26,6 @@ Requires-Dist: eth-hash[pycryptodome] >=0.5.1
|
|
|
26
26
|
Requires-Dist: eth-typing >=3.0.0
|
|
27
27
|
Requires-Dist: eth-utils >=4.0.0
|
|
28
28
|
Requires-Dist: hexbytes <0.4.0,>=0.1.0
|
|
29
|
-
Requires-Dist: jsonschema >=4.0.0
|
|
30
|
-
Requires-Dist: protobuf >=4.21.6
|
|
31
29
|
Requires-Dist: pydantic >=2.4.0
|
|
32
30
|
Requires-Dist: requests >=2.16.0
|
|
33
31
|
Requires-Dist: typing-extensions >=4.0.1
|
|
@@ -38,16 +36,15 @@ Provides-Extra: dev
|
|
|
38
36
|
Requires-Dist: eth-tester[py-evm] ==v0.10.0-b.3 ; extra == 'dev'
|
|
39
37
|
Requires-Dist: py-geth >=4.1.0 ; extra == 'dev'
|
|
40
38
|
Requires-Dist: black >=22.1.0 ; extra == 'dev'
|
|
39
|
+
Requires-Dist: blocklint >=0.2.4 ; extra == 'dev'
|
|
41
40
|
Requires-Dist: flake8 ==3.8.3 ; extra == 'dev'
|
|
42
41
|
Requires-Dist: isort >=5.11.0 ; extra == 'dev'
|
|
43
42
|
Requires-Dist: mypy ==1.4.1 ; extra == 'dev'
|
|
44
43
|
Requires-Dist: types-setuptools >=57.4.4 ; extra == 'dev'
|
|
45
44
|
Requires-Dist: types-requests >=2.26.1 ; extra == 'dev'
|
|
46
|
-
Requires-Dist: types-protobuf ==3.19.13 ; extra == 'dev'
|
|
47
45
|
Requires-Dist: sphinx >=5.3.0 ; extra == 'dev'
|
|
48
46
|
Requires-Dist: sphinx-rtd-theme >=1.0.0 ; extra == 'dev'
|
|
49
47
|
Requires-Dist: towncrier <22,>=21 ; extra == 'dev'
|
|
50
|
-
Requires-Dist: ipfshttpclient ==0.8.0a2 ; extra == 'dev'
|
|
51
48
|
Requires-Dist: bumpversion ; extra == 'dev'
|
|
52
49
|
Requires-Dist: flaky >=3.7.0 ; extra == 'dev'
|
|
53
50
|
Requires-Dist: hypothesis >=3.31.2 ; extra == 'dev'
|
|
@@ -60,23 +57,20 @@ Requires-Dist: setuptools >=38.6.0 ; extra == 'dev'
|
|
|
60
57
|
Requires-Dist: tox >=3.18.0 ; extra == 'dev'
|
|
61
58
|
Requires-Dist: tqdm >4.32 ; extra == 'dev'
|
|
62
59
|
Requires-Dist: twine >=1.13 ; extra == 'dev'
|
|
63
|
-
Requires-Dist: when-changed >=0.3.0 ; extra == 'dev'
|
|
64
60
|
Requires-Dist: build >=0.9.0 ; extra == 'dev'
|
|
65
61
|
Requires-Dist: importlib-metadata <5.0 ; (python_version < "3.8") and extra == 'dev'
|
|
66
62
|
Provides-Extra: docs
|
|
67
63
|
Requires-Dist: sphinx >=5.3.0 ; extra == 'docs'
|
|
68
64
|
Requires-Dist: sphinx-rtd-theme >=1.0.0 ; extra == 'docs'
|
|
69
65
|
Requires-Dist: towncrier <22,>=21 ; extra == 'docs'
|
|
70
|
-
Provides-Extra: ipfs
|
|
71
|
-
Requires-Dist: ipfshttpclient ==0.8.0a2 ; extra == 'ipfs'
|
|
72
66
|
Provides-Extra: linter
|
|
73
67
|
Requires-Dist: black >=22.1.0 ; extra == 'linter'
|
|
68
|
+
Requires-Dist: blocklint >=0.2.4 ; extra == 'linter'
|
|
74
69
|
Requires-Dist: flake8 ==3.8.3 ; extra == 'linter'
|
|
75
70
|
Requires-Dist: isort >=5.11.0 ; extra == 'linter'
|
|
76
71
|
Requires-Dist: mypy ==1.4.1 ; extra == 'linter'
|
|
77
72
|
Requires-Dist: types-setuptools >=57.4.4 ; extra == 'linter'
|
|
78
73
|
Requires-Dist: types-requests >=2.26.1 ; extra == 'linter'
|
|
79
|
-
Requires-Dist: types-protobuf ==3.19.13 ; extra == 'linter'
|
|
80
74
|
Provides-Extra: tester
|
|
81
75
|
Requires-Dist: eth-tester[py-evm] ==v0.10.0-b.3 ; extra == 'tester'
|
|
82
76
|
Requires-Dist: py-geth >=4.1.0 ; extra == 'tester'
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
ens/__init__.py,sha256=Dtb57dzb4nLJbtR-XCziJs075vqNpmNfiDSIVe5EPnE,285
|
|
2
|
+
ens/_normalization.py,sha256=cj9EWUFtKwiYEoX-2PfrcVv5VRYm-oy-CX9cDjegZrE,16788
|
|
3
|
+
ens/abis.py,sha256=0Ec_lqe7HBsVpQrID3ccFMhx8Vb7S0TGFbeuRdXhuCE,34745
|
|
4
|
+
ens/async_ens.py,sha256=j0BoBfik1FeLui26GI9S-rUBE1zPpeBnBZL5bDDTwWU,22333
|
|
5
|
+
ens/auto.py,sha256=w_E6Ua5ZmJVxfdii2aG5I_kQG5B9U5Y2qIFKVNhXo98,41
|
|
6
|
+
ens/base_ens.py,sha256=BTYB5SCkif5r08Aou7haMhJABaggOHn3S4tUW4MLsVo,3477
|
|
7
|
+
ens/constants.py,sha256=XCO4Pntwdnw10K_AZ86V0cqcvdUoOkEZvRqoDdFPE_w,913
|
|
8
|
+
ens/contract_data.py,sha256=ZF8wMZDXbhd3q1Qn5ishjbASQf4QoDAMUet9ySTwmVU,148604
|
|
9
|
+
ens/ens.py,sha256=XlVZ7k9hC_HOiOFD7LCZQ-rroVfq2TTle_oSfrXSbmc,21605
|
|
10
|
+
ens/exceptions.py,sha256=g15oQhT3cbhniGjAmboC2M7xKGGNDfMutSnfK0LMqvs,2326
|
|
11
|
+
ens/utils.py,sha256=Ah9EVu-ch8nWMzMoFSYrkGMzJA61-zwT5Qc5Homs1JI,9317
|
|
12
|
+
ens/specs/nf.json,sha256=EnLJQWU7usNO-EBe1SessY2CioM4H_HXTRvxU__0Ufw,48402
|
|
13
|
+
ens/specs/normalization_spec.json,sha256=liMWlkVT_OYYjiWlFmpMHpBjM631O98pZMcd7cD44sg,3115333
|
|
14
|
+
web3/__init__.py,sha256=ZKNvCbdKGK7fBlUIGBOiIoBaEsvnKIjF0GpZZpNF5h4,1068
|
|
15
|
+
web3/constants.py,sha256=eQLRQVMFPbgpOjjkPTMHkY-syncJuO-sPX5UrCSRjzQ,564
|
|
16
|
+
web3/datastructures.py,sha256=ylvV3sgXsovIwbg9cXiHXdIZHdCIMzPwxMY1SeJVUSM,10716
|
|
17
|
+
web3/exceptions.py,sha256=u0qTr7mS9wEmh-0jSfXNlEzJ-Sfigr4MwF6HxE7_wUw,6904
|
|
18
|
+
web3/geth.py,sha256=1DRMSCErpCxL7l0406z5K46P8ORmtS87ZMyLowwK9LI,11329
|
|
19
|
+
web3/logs.py,sha256=ROs-mDMH_ZOecE7hfbWA5yp27G38FbLjX4lO_WtlZxQ,198
|
|
20
|
+
web3/main.py,sha256=-75d38t4aGjJNbbcUOnlE2s0jdIw34UDODHjVVzaBTo,13987
|
|
21
|
+
web3/manager.py,sha256=Sz2xseY3WxppPXLPpBoIvK51FqiN9VstY1UK69LlTgU,15030
|
|
22
|
+
web3/method.py,sha256=3q8SnB6z3KKVfYYlDHoPCuQd-gYdjYkQWy8Q4Y5_L0U,7766
|
|
23
|
+
web3/module.py,sha256=zonvW0meqdfG82-KgtYTF9ketsCShK2m9b-HYRBJRZg,4793
|
|
24
|
+
web3/net.py,sha256=Y3vPzHWVFkfHEZoJxjDOt4tp5ERmZrMuyi4ZFOLmIeA,1562
|
|
25
|
+
web3/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
26
|
+
web3/testing.py,sha256=X7rKGcuEbRCvwXlWuJOfzZvXHboIEeoK-bIWnF_zn1A,951
|
|
27
|
+
web3/tracing.py,sha256=OBRKLfoSSstzUrk-oqkrbPYPTNGTaPX7-VO5iEt1FwY,2968
|
|
28
|
+
web3/types.py,sha256=Cf-YKolEoS39PQxahxccyhdUcPYHFq6-S06KXn26cDk,12534
|
|
29
|
+
web3/_utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
30
|
+
web3/_utils/abi.py,sha256=OOnpQSGVAPgbgCXcxGypmhMMj1tq27HXyqPYrTqkchU,30587
|
|
31
|
+
web3/_utils/async_caching.py,sha256=2XnaKCHBTTDK6B2R_YZvjJqIRUpbMDIU1uYrq-Lcyp8,486
|
|
32
|
+
web3/_utils/async_transactions.py,sha256=R4w5CL4g0SCEPO8THKHRV_C-UxVuFDDNyecPRw-yx40,5161
|
|
33
|
+
web3/_utils/blocks.py,sha256=l4w71UErmuZayZOBMxvqB6aqIpMS4Nx24m4gsYBoOO0,2059
|
|
34
|
+
web3/_utils/caching.py,sha256=abFhXWAdrtT3TBtfD3uC8EqUhNUAymqZ3tAW3wFnCpY,4789
|
|
35
|
+
web3/_utils/contracts.py,sha256=3sFLshwf8pV2FN6tMwt6b3aZFz7kBm0wfl3_ZQSRt8k,14323
|
|
36
|
+
web3/_utils/datatypes.py,sha256=kdHO-crgPKfSvSFg6GSdZrlJq3Gxs6zAC337DA-6MKM,1640
|
|
37
|
+
web3/_utils/decorators.py,sha256=GKaEFqyZJvvrXOcxutlN6CvWLQU7ZTiHHwcbslixJ0c,1738
|
|
38
|
+
web3/_utils/empty.py,sha256=jd7-bwIhNLfBjns5WRDCeN1aT1reGgTZ1XlT6olTs3U,144
|
|
39
|
+
web3/_utils/encoding.py,sha256=VW_-lDqQsEjqrA34Ea8v4Lj8_y3ZHL6EnTGJK-jt5rw,9117
|
|
40
|
+
web3/_utils/ens.py,sha256=2BvzfegBkR7vH3Fq7lo_LsgfT912Zj-mR8eUt6o_lBA,2434
|
|
41
|
+
web3/_utils/error_formatters_utils.py,sha256=0D1Dc6QojWgG2JSJmdjnFjs3k-ylKItygTulI7XZXco,6809
|
|
42
|
+
web3/_utils/events.py,sha256=6vebSk4klDRHykZ_9Dv0N9omam8OQOU8EWUdVEv2TAY,17498
|
|
43
|
+
web3/_utils/fee_utils.py,sha256=65Z6pPaPz39gsCVIyQwM2y1qfOUNc-4hlGbYAqAteVA,2145
|
|
44
|
+
web3/_utils/filters.py,sha256=MTgJGMw2hHmrxtaJmWO-0DjQ5OCbwY0kOoT-OglgPDc,11996
|
|
45
|
+
web3/_utils/formatters.py,sha256=xcLQIRxL07vHHTwfsdGEGS7LGzY1_tf5mSnTS9KTfoM,3071
|
|
46
|
+
web3/_utils/function_identifiers.py,sha256=m305lsvUZk-jkPixT0IJd9P5sXqMvmwlwlLeBgEAnBQ,55
|
|
47
|
+
web3/_utils/http.py,sha256=GDHmbeWt7UoHkRBvFt9Py5Vzr2ZLzH9WxAqEYZCJ53s,205
|
|
48
|
+
web3/_utils/hypothesis.py,sha256=4Cm4iOWv-uP9irg_Pv63kYNDYUAGhnUH6fOPWRw3A0g,209
|
|
49
|
+
web3/_utils/math.py,sha256=g6iSVKaKgCofjAC60MC2yTtlhNoezHQppJ3EAbpLwXs,1055
|
|
50
|
+
web3/_utils/method_formatters.py,sha256=kg4xkDXyH-a4CnB-vXL1pYgQWhanVudSNYjVFmkdGC4,33918
|
|
51
|
+
web3/_utils/module.py,sha256=s3oqAZpR5hlbGrHkFNNtqavNqciAQjNkMrMYke-mYlg,3147
|
|
52
|
+
web3/_utils/normalizers.py,sha256=jb-tMhWyNKWv1TJyrECwOeyDGAGON67jKb0Iz-Rxlcw,7447
|
|
53
|
+
web3/_utils/request.py,sha256=PC_UMluqlaJECfiqEyLAiLKff_lz49sOqK0-77iVpw8,8881
|
|
54
|
+
web3/_utils/rpc_abi.py,sha256=IYKHWrHOHpEajZP0mAx4xE5Qr-UzVlF-8SbFzsXBCwg,9357
|
|
55
|
+
web3/_utils/threads.py,sha256=ZaBg_daNU_eI3nWtyAR8aQYM-ETTSoNchpfRyw6lEbQ,4208
|
|
56
|
+
web3/_utils/transactions.py,sha256=YaFDLXS69F75WJ9ccXkUJHZLebAJactHFpWR12y7jFk,8839
|
|
57
|
+
web3/_utils/type_conversion.py,sha256=P9ojTqFASnlFEIA_Pf_BA3YJB4Ok4P0E_aGJw7FinNc,816
|
|
58
|
+
web3/_utils/utility_methods.py,sha256=7VCpo5ysvPoGjFuDj5gT1Niva2l3BADUvNeJFlL3Yvg,2559
|
|
59
|
+
web3/_utils/validation.py,sha256=5JBDbu8Azw4bgmN-QARRh6WFiZiX2VABl2zVsv9z0rc,6291
|
|
60
|
+
web3/_utils/windows.py,sha256=IlFUtqYSbUUfFRx60zvEwpiZd080WpOrA4ojm4tmSEE,994
|
|
61
|
+
web3/_utils/compat/__init__.py,sha256=TqX3GLnPutBwXIl0QDrFNK-qRDWFOgYKz7IgwfbuD48,592
|
|
62
|
+
web3/_utils/contract_sources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
63
|
+
web3/_utils/contract_sources/compile_contracts.py,sha256=nGrpgb7exjHBphyYg4hbBey_W9MbmgLVfwGkzdPAvXE,6491
|
|
64
|
+
web3/_utils/contract_sources/contract_data/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
65
|
+
web3/_utils/contract_sources/contract_data/_custom_contract_data.py,sha256=nxpN2uS1T338Tp5uVhwY9U1C2m2pdDz7kZv3LoZ0hpo,552
|
|
66
|
+
web3/_utils/contract_sources/contract_data/address_reflector.py,sha256=oBddZz6wMCf7CZ8UFL_i2XWl7b8qwsHrJrgrEBn8hFw,5344
|
|
67
|
+
web3/_utils/contract_sources/contract_data/arrays_contract.py,sha256=hJM6jVsTqWPsyLiHdI3Lg5FH_LphlE91yFn5bfT-W3k,18852
|
|
68
|
+
web3/_utils/contract_sources/contract_data/bytes_contracts.py,sha256=nTTVEvKBIT-2FfmFw9471HxPvUi8GuIe4MNNi2iPDd4,14783
|
|
69
|
+
web3/_utils/contract_sources/contract_data/constructor_contracts.py,sha256=5CjW-TIZWB08pRRulbB08634-WIzIiysQsr4rctyEQo,6089
|
|
70
|
+
web3/_utils/contract_sources/contract_data/contract_caller_tester.py,sha256=NI3CH0TSFXZXNujqrNm3A9yQJLzG23TrA4dvLPeT-CM,6334
|
|
71
|
+
web3/_utils/contract_sources/contract_data/emitter_contract.py,sha256=tsQA_dj6JJNMoRs1YJH-PzSCfTPVN1NuLZBnTZZylhk,40967
|
|
72
|
+
web3/_utils/contract_sources/contract_data/event_contracts.py,sha256=DUYrlFubw53DlIo1RL7roS_OVJI_A0hVmo8DZU9ythw,5573
|
|
73
|
+
web3/_utils/contract_sources/contract_data/extended_resolver.py,sha256=wL5hWALeAKXhB9KSI3fUijRs8GlsEC0OZg5DOaaBEog,15824
|
|
74
|
+
web3/_utils/contract_sources/contract_data/fallback_function_contract.py,sha256=y8YFW9nWpt4rclQtLlXieuZv2qsskz8F-Rcv1Ihmwx8,1651
|
|
75
|
+
web3/_utils/contract_sources/contract_data/function_name_tester_contract.py,sha256=68RxXutgPj05TJU6ism4f5qO4ypVnRr6hts_L1CXDbI,1886
|
|
76
|
+
web3/_utils/contract_sources/contract_data/math_contract.py,sha256=unrYYyilwvVdNJ0vzmMzlQ7vD2dJVX7DBgLT15f6Im8,7637
|
|
77
|
+
web3/_utils/contract_sources/contract_data/offchain_lookup.py,sha256=4k6UiBS9S8Ga3n_38IOikPtjzt5G39uqjxL_wO-AXhk,16716
|
|
78
|
+
web3/_utils/contract_sources/contract_data/offchain_resolver.py,sha256=mwzJvyorsnY3ZlZn1N0A9Me6Pm74nvXi-wn4AcUf93w,32387
|
|
79
|
+
web3/_utils/contract_sources/contract_data/panic_errors_contract.py,sha256=S5r3hffZxqHfMG2UfVwy4-ne14lL9miqazToCKx_RrM,15579
|
|
80
|
+
web3/_utils/contract_sources/contract_data/payable_tester.py,sha256=zKw04ItPZF0kQ8Y_XAhLhwDM-83Y_CNzQyw97u_Hb38,1825
|
|
81
|
+
web3/_utils/contract_sources/contract_data/receive_function_contracts.py,sha256=qcEweZoyhYQym0GipZw-BpfNk1IMUiu3Fui1sZDEMI0,17290
|
|
82
|
+
web3/_utils/contract_sources/contract_data/reflector_contracts.py,sha256=9yGPBokbDjSL1P4_CEIjBm_S5hi77mgeve7USUSpYQI,5264
|
|
83
|
+
web3/_utils/contract_sources/contract_data/revert_contract.py,sha256=YOIXuOw4PER9S3HuiiJ-yKbhlYpx9lwSmjfOyETSsro,4264
|
|
84
|
+
web3/_utils/contract_sources/contract_data/simple_resolver.py,sha256=WveX0v15U64yWGO5N51Gzng7iMZh_RW80DZ9JCa7WhI,3555
|
|
85
|
+
web3/_utils/contract_sources/contract_data/storage_contract.py,sha256=NhoWNlWltNtGBdPwCWQGQfDO4hDTRXCVPWx7jSc58B0,8238
|
|
86
|
+
web3/_utils/contract_sources/contract_data/string_contract.py,sha256=zZdglZ6se_aqMIUKN3-3zR57h8zyDyUQIgtSIXtdSzg,11586
|
|
87
|
+
web3/_utils/contract_sources/contract_data/tuple_contracts.py,sha256=qt0cGM1Kh-LlRYn04-fpSPQJAWcGrvP8EKPCJvsrnvE,23180
|
|
88
|
+
web3/_utils/module_testing/__init__.py,sha256=_AuZ0S4xesS7ocRdMHeTN6zju7KqpSsG4NXgmccJonU,455
|
|
89
|
+
web3/_utils/module_testing/eth_module.py,sha256=yEYd-at1TFPOWMw2yFd2sRQidkCeMUuwfyjcAoEOeBU,184153
|
|
90
|
+
web3/_utils/module_testing/go_ethereum_admin_module.py,sha256=_c-6SyzZkfAJ-7ySXUpw9FEr4cg-ShRdAGSAHWanCtY,3406
|
|
91
|
+
web3/_utils/module_testing/go_ethereum_personal_module.py,sha256=PRX1dxqxGydHWyzcGVa0EP0IUoiSQyDYaszbmmXDKTU,10432
|
|
92
|
+
web3/_utils/module_testing/go_ethereum_txpool_module.py,sha256=5f8XL8-2x3keyGRaITxMQYl9oQzjgqGn8zobB-j9BPs,1176
|
|
93
|
+
web3/_utils/module_testing/module_testing_utils.py,sha256=AC1AGQPQQriABK1Q9hsbODGKzRGlgcuiM7bB3xnbly4,5594
|
|
94
|
+
web3/_utils/module_testing/net_module.py,sha256=ifUTC-5fTcQbwpm0X09OdD5RSPnn00T8klFeYe8tTm4,1272
|
|
95
|
+
web3/_utils/module_testing/persistent_connection_provider.py,sha256=RDcyBIznwweuG2X-57vq1jhMqYMK9lJRDEpaXuljwuE,16567
|
|
96
|
+
web3/_utils/module_testing/utils.py,sha256=KkS0nbpj8b0DuBTh4hNejGwMqur6uEZi2mswmi-DMNI,9632
|
|
97
|
+
web3/_utils/module_testing/web3_module.py,sha256=Y4lYglg_kbrpfwGfjekv52h4B7DaWa3uS15KGrCKL7c,9613
|
|
98
|
+
web3/auto/__init__.py,sha256=ZbzAiCZMdt_tCTTPvH6t8NCVNroKKkt7TSVBBNR74Is,44
|
|
99
|
+
web3/auto/gethdev.py,sha256=MuWD2gxv0xDv_SzPsp9mSkS1oG4P54xFK83qw9NvswA,438
|
|
100
|
+
web3/beacon/__init__.py,sha256=8VmlbCbMiZBpEISoMcz72MoewtQxlUBk9FCfYud3Elw,65
|
|
101
|
+
web3/beacon/api_endpoints.py,sha256=dkekSCmkat5QIfwKzwm49CyVcRb-pIbn1nZHB4F8M0U,2208
|
|
102
|
+
web3/beacon/async_beacon.py,sha256=y7cvbsDYjRNDZftzcJyXaSLCsRrASAGxfyCwE53oCG4,7472
|
|
103
|
+
web3/beacon/beacon.py,sha256=wgSmF-5hu_95L6onnlA33ADDoASFf9OZf-YWnqnY0VY,6640
|
|
104
|
+
web3/contract/__init__.py,sha256=EX_RmT8D2DDKKsk1U8grCNdLq9b1rF-8xWaR53CBiew,187
|
|
105
|
+
web3/contract/async_contract.py,sha256=oxxq5Pse4JkrRvPnecbF5eYwKg_FX17ltiHLvxiRj6Q,20392
|
|
106
|
+
web3/contract/base_contract.py,sha256=KuexzVWApCVL5c1VTMPZHDI40K20SR_JrqHWfjZJd0o,37552
|
|
107
|
+
web3/contract/contract.py,sha256=mNrGoMvxdKHRecoMxT7KDEWK0hCKqPoH6DX7yqD78As,19997
|
|
108
|
+
web3/contract/utils.py,sha256=ozHDwk1JoCYlFV6LX2upYlgQhcW6zOP4eQ0jOHJzboA,12462
|
|
109
|
+
web3/eth/__init__.py,sha256=CrYZXIlIdKTmznnLNUaA-C3eLvftBnmlVt9uxm-dwAI,124
|
|
110
|
+
web3/eth/async_eth.py,sha256=4Ook7jJD93KAk-qs4QNOR-R6ct5F7AvQx3fqQhoMBIY,23929
|
|
111
|
+
web3/eth/base_eth.py,sha256=WC1BRE1QOhPV417Od2NSu28fnyXTjKQ9YVqTU3W3N0A,6822
|
|
112
|
+
web3/eth/eth.py,sha256=4hSSI0bIoGnOdc4yJz2dMH_Wrt3jxcB-3hMqlwU7xI4,20839
|
|
113
|
+
web3/gas_strategies/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
114
|
+
web3/gas_strategies/rpc.py,sha256=3Va-32jdmHkX7tzQCmh17ms2D6te5zZcqHP1326BdpY,352
|
|
115
|
+
web3/gas_strategies/time_based.py,sha256=xWj3WyA8UL76KTNAbMWLiWwD-UYuWyFttclHoXuP1gg,9169
|
|
116
|
+
web3/middleware/__init__.py,sha256=3aCt9x2A9x_Hg0QnqsN0MDbm2yw2WFTNjzlt1ytYrdQ,2414
|
|
117
|
+
web3/middleware/attrdict.py,sha256=NY5yxlFOfLBBmcIjl8R-uP2dTz9ITIyTttG8-QcJWCI,2259
|
|
118
|
+
web3/middleware/base.py,sha256=Ovw2HXX-6B2nAiN7PjTPQnujAP15idMLoPF2tCZqaWY,3519
|
|
119
|
+
web3/middleware/buffered_gas_estimate.py,sha256=EmxUd-uO959UVroPsPKkl7oDa8Tw6N8BQLB6Urng5Eo,1647
|
|
120
|
+
web3/middleware/filter.py,sha256=62Zs-fKS3nMU1aChMEJbXNof7mni5tj30ivaDrRDBJU,21778
|
|
121
|
+
web3/middleware/formatting.py,sha256=UHvhlYdoAArqYKR8EFaLsdeU5snQQut6wx8olUcmkIc,7507
|
|
122
|
+
web3/middleware/gas_price_strategy.py,sha256=ZjZ6pe3z0mDGLZHYoFXp4_fZIePqukljEh9f4mZUyIA,3779
|
|
123
|
+
web3/middleware/names.py,sha256=m9Hj8v5xwJuXE3L_bKjj5Li0gZHS0I-V-OcUIZUruoA,4257
|
|
124
|
+
web3/middleware/proof_of_authority.py,sha256=0AT4jr5CmTdrvl8Jiy-WYy8IFDYBOEaesgHDwpn0c7M,1429
|
|
125
|
+
web3/middleware/pythonic.py,sha256=awc8I6lLzVc2Iv138sps2uf6dMQipskLRBTdvTEEIgQ,348
|
|
126
|
+
web3/middleware/signing.py,sha256=jdH1LdD2Y2XbTMIcPFQgna4_nrawy5X8861zpo5m_6s,5680
|
|
127
|
+
web3/middleware/stalecheck.py,sha256=FazqyU1rNHg6vPOMJhSg68qG3d8TPLIgId-yvk080N4,2656
|
|
128
|
+
web3/middleware/validation.py,sha256=QxActrJk_zsXXiwpadP2MUjZBS5E50OJOtUwVrm9XVo,4280
|
|
129
|
+
web3/providers/__init__.py,sha256=PLRNgSNqMjXKGM-qAatJTGSaQjmjzQW6jYxS3lVX_w0,470
|
|
130
|
+
web3/providers/async_base.py,sha256=NGmg36qihjvhnx1OXIB0fg2kkc0rbFlJV5iFPzr0nGY,5323
|
|
131
|
+
web3/providers/auto.py,sha256=Zx3CHKoRkmiw3Jte2BLNPiJAFd8rDXNGfA3XtxZvHgc,3465
|
|
132
|
+
web3/providers/base.py,sha256=47r2USOZP3cc78fk2K8yFR7MoI2AMqKClGltPqbV4Xg,4468
|
|
133
|
+
web3/providers/ipc.py,sha256=ss2ieRz0rou7CHnzGihNnQX1S3KbU2_QsiDCy6RN0ic,5688
|
|
134
|
+
web3/providers/legacy_websocket.py,sha256=TuGCB26n9b9USXLUFNI5htKNZV7f_5pfsl_iro2N9e4,3953
|
|
135
|
+
web3/providers/eth_tester/__init__.py,sha256=J6wazY3hQySsUfpFgwCXbEMo-CGEZjRo11RCg4UXKmA,83
|
|
136
|
+
web3/providers/eth_tester/defaults.py,sha256=KpvHDHIoDw8rqUvToKl1LezNyod0TzxoMw7J3fLeUCg,14512
|
|
137
|
+
web3/providers/eth_tester/main.py,sha256=I7NuZT8fA2CoSN-I-3UekcXrY-P1wb7sa6tzeQy502k,7196
|
|
138
|
+
web3/providers/eth_tester/middleware.py,sha256=ZV8JFObcCzIKi_Xkne00qW-ttDmp30iTveXJps5IOvU,12882
|
|
139
|
+
web3/providers/persistent/__init__.py,sha256=S1s8m1cjPOjD-CCrWrLDP0PGlP1FUqgEw2KdrDeMPgk,283
|
|
140
|
+
web3/providers/persistent/async_ipc.py,sha256=FW01Z5hzT0NE0izCN5AVMZIYbHxpqCR62tzt2xNO6Dw,7277
|
|
141
|
+
web3/providers/persistent/persistent.py,sha256=qvozc8VX8Xv0JFPUcHdHsi6FpdD-QrAirKFinSl2i_I,3556
|
|
142
|
+
web3/providers/persistent/persistent_connection.py,sha256=56yjpwDMM2phkJ_M5_QB-A6_CjZc5VrkWhNDweA70d0,1109
|
|
143
|
+
web3/providers/persistent/request_processor.py,sha256=zneKvSK7nopN0V2qo7O5halnXTUgneJteSibss06YSI,11495
|
|
144
|
+
web3/providers/persistent/utils.py,sha256=gfY7w1HB8xuE7OujSrbwWYjQuQ8nzRBoxoL8ESinqWM,1140
|
|
145
|
+
web3/providers/persistent/websocket.py,sha256=N70-qqitPT5eqNdlQrvZXgETabG3ZImTv99111LkgX8,6914
|
|
146
|
+
web3/providers/rpc/__init__.py,sha256=d20CaZ6vOXlud5sh6I5JnT_zEGBMpbXl-vCDFMxBNoY,89
|
|
147
|
+
web3/providers/rpc/async_rpc.py,sha256=2_xh4RYSPU3_ELcRXuc-10ZEZWppxhVRKFi9OmlIbOU,4136
|
|
148
|
+
web3/providers/rpc/rpc.py,sha256=SQHm34TiBmy03f-XApJt9iNYTluePf-hz5sFxt2Rpw4,4230
|
|
149
|
+
web3/providers/rpc/utils.py,sha256=hjw0_tzBvJ6eBsQak9xzo37ODMGhKTAlLjeSoSZk39k,2458
|
|
150
|
+
web3/scripts/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
151
|
+
web3/scripts/release/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
152
|
+
web3/scripts/release/test_package.py,sha256=DH0AryllcF4zfpWSd0NLPSQGHNoC-Qng5WYYbS5_4c8,1534
|
|
153
|
+
web3/tools/benchmark/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
154
|
+
web3/tools/benchmark/main.py,sha256=OAT7klotT1vnFO5AKo4PB9D9nRTb4BeLl7Lcj55yzcw,5356
|
|
155
|
+
web3/tools/benchmark/node.py,sha256=IYyXmVyACF6R0xch9_9Ow24a7HuH8aOcZ2iA2sxOYvo,3501
|
|
156
|
+
web3/tools/benchmark/reporting.py,sha256=G2bj_Eo2kBV06GARDYK9zr0VqesiR0_5JLKvhAo6zRM,912
|
|
157
|
+
web3/tools/benchmark/utils.py,sha256=GjSofFEq3ugFtpyBlAx7n6cgZrQ5Xu4-hN_36bQBwnA,1722
|
|
158
|
+
web3/utils/__init__.py,sha256=pswH3MW_mro5zrHn_q8Pto-iS1jrbtEH3UtQ9qioiKM,455
|
|
159
|
+
web3/utils/abi.py,sha256=naNkD7_XQGV8hd4CkxytLKWCcgzUjkb7q3ERwRVNICI,498
|
|
160
|
+
web3/utils/address.py,sha256=KC_IpEbixSCuMhaW6V2QCyyJTYKYGS9c8QtI9_aH7zQ,967
|
|
161
|
+
web3/utils/async_exception_handling.py,sha256=gfLuzP7Y5rc21jZVjWEYAOZUMJkJd9CmsL297UKReow,3096
|
|
162
|
+
web3/utils/caching.py,sha256=4U-vh61m1dlslwEn_Nl7ybIlMF4W2IAcvMTH-iFzrNM,1618
|
|
163
|
+
web3/utils/exception_handling.py,sha256=12xkzIqMAOx0Jcm6PYL98PmWlLPKFll0p9YoLGS_ZNg,3052
|
|
164
|
+
web3-7.0.0b3.dist-info/LICENSE,sha256=ulnXiEqqFp9VyWe8yMFdtDi70RMBJk3mpY3FKujv6l8,1090
|
|
165
|
+
web3-7.0.0b3.dist-info/METADATA,sha256=thR0SIhg9znLbCimjfWjHS2iwW5OodxYkbSh-8PqV6c,4605
|
|
166
|
+
web3-7.0.0b3.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
167
|
+
web3-7.0.0b3.dist-info/top_level.txt,sha256=iwupuJh7wgypXrpk_awszyri3TahRr5vxSphNyvt1bU,9
|
|
168
|
+
web3-7.0.0b3.dist-info/RECORD,,
|
ethpm/__init__.py
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
from pathlib import Path
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
ETHPM_DIR = Path(__file__).parent
|
|
5
|
-
ASSETS_DIR = ETHPM_DIR / "assets"
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
def get_ethpm_spec_dir() -> Path:
|
|
9
|
-
ethpm_spec_dir = ETHPM_DIR / "ethpm-spec"
|
|
10
|
-
v3_spec = ethpm_spec_dir / "spec" / "v3.spec.json"
|
|
11
|
-
if not v3_spec.is_file():
|
|
12
|
-
raise FileNotFoundError(
|
|
13
|
-
"The ethpm-spec submodule is not available. "
|
|
14
|
-
"Please import the submodule with `git submodule update --init`"
|
|
15
|
-
)
|
|
16
|
-
return ethpm_spec_dir
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
from .package import Package # noqa: E402, F401
|
|
20
|
-
from .backends.registry import RegistryURI # noqa: E402, F401
|
ethpm/_utils/__init__.py
DELETED
|
File without changes
|
ethpm/_utils/backend.py
DELETED
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import logging
|
|
2
|
-
from typing import (
|
|
3
|
-
Generator,
|
|
4
|
-
Type,
|
|
5
|
-
)
|
|
6
|
-
|
|
7
|
-
from eth_typing import (
|
|
8
|
-
URI,
|
|
9
|
-
)
|
|
10
|
-
from eth_utils import (
|
|
11
|
-
to_tuple,
|
|
12
|
-
)
|
|
13
|
-
|
|
14
|
-
from ethpm.backends.base import (
|
|
15
|
-
BaseURIBackend,
|
|
16
|
-
)
|
|
17
|
-
from ethpm.backends.http import (
|
|
18
|
-
GithubOverHTTPSBackend,
|
|
19
|
-
)
|
|
20
|
-
from ethpm.backends.ipfs import (
|
|
21
|
-
DummyIPFSBackend,
|
|
22
|
-
InfuraIPFSBackend,
|
|
23
|
-
LocalIPFSBackend,
|
|
24
|
-
get_ipfs_backend_class,
|
|
25
|
-
)
|
|
26
|
-
from ethpm.backends.registry import (
|
|
27
|
-
RegistryURIBackend,
|
|
28
|
-
)
|
|
29
|
-
|
|
30
|
-
try:
|
|
31
|
-
from ipfshttpclient.exceptions import (
|
|
32
|
-
ConnectionError as IpfsConnectionError,
|
|
33
|
-
)
|
|
34
|
-
except ImportError:
|
|
35
|
-
pass
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
logger = logging.getLogger("ethpm.utils.backend")
|
|
39
|
-
|
|
40
|
-
ALL_URI_BACKENDS = [
|
|
41
|
-
InfuraIPFSBackend,
|
|
42
|
-
DummyIPFSBackend,
|
|
43
|
-
LocalIPFSBackend,
|
|
44
|
-
GithubOverHTTPSBackend,
|
|
45
|
-
RegistryURIBackend,
|
|
46
|
-
]
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
def _handle_optional_ipfs_backend_exception(e: Exception) -> None:
|
|
50
|
-
try:
|
|
51
|
-
# if optional `ipfshttpclient` module is present, catch and debug if
|
|
52
|
-
# IpfsConnectionError, else raise original exception.
|
|
53
|
-
if isinstance(e, IpfsConnectionError):
|
|
54
|
-
logger.debug("No local IPFS node available on port 5001.", exc_info=True)
|
|
55
|
-
else:
|
|
56
|
-
raise e
|
|
57
|
-
except NameError:
|
|
58
|
-
# if optional `ipfshttpclient` module is not present, raise original exception
|
|
59
|
-
raise e
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
@to_tuple
|
|
63
|
-
def get_translatable_backends_for_uri(
|
|
64
|
-
uri: URI,
|
|
65
|
-
) -> Generator[Type[BaseURIBackend], None, None]:
|
|
66
|
-
# type ignored because of conflict with instantiating BaseURIBackend
|
|
67
|
-
for backend in ALL_URI_BACKENDS:
|
|
68
|
-
try:
|
|
69
|
-
if backend().can_translate_uri(uri): # type: ignore
|
|
70
|
-
yield backend
|
|
71
|
-
except Exception as e:
|
|
72
|
-
_handle_optional_ipfs_backend_exception(e)
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
@to_tuple
|
|
76
|
-
def get_resolvable_backends_for_uri(
|
|
77
|
-
uri: URI,
|
|
78
|
-
) -> Generator[Type[BaseURIBackend], None, None]:
|
|
79
|
-
# special case the default IPFS backend to the first slot.
|
|
80
|
-
default_ipfs = get_ipfs_backend_class()
|
|
81
|
-
if default_ipfs in ALL_URI_BACKENDS and default_ipfs().can_resolve_uri(uri):
|
|
82
|
-
yield default_ipfs
|
|
83
|
-
else:
|
|
84
|
-
for backend_class in ALL_URI_BACKENDS:
|
|
85
|
-
if backend_class is default_ipfs:
|
|
86
|
-
continue
|
|
87
|
-
# type ignored because of conflict with instantiating BaseURIBackend
|
|
88
|
-
else:
|
|
89
|
-
try:
|
|
90
|
-
if backend_class().can_resolve_uri(uri): # type: ignore
|
|
91
|
-
yield backend_class
|
|
92
|
-
except Exception as e:
|
|
93
|
-
_handle_optional_ipfs_backend_exception(e)
|
ethpm/_utils/cache.py
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
from typing import (
|
|
2
|
-
Any,
|
|
3
|
-
Callable,
|
|
4
|
-
)
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
class cached_property:
|
|
8
|
-
"""
|
|
9
|
-
Decorator that converts a method with a single self argument into a
|
|
10
|
-
property cached on the instance.
|
|
11
|
-
|
|
12
|
-
Optional ``name`` argument allows you to make cached properties of other
|
|
13
|
-
methods. (e.g. url = cached_property(get_absolute_url, name='url') )
|
|
14
|
-
"""
|
|
15
|
-
|
|
16
|
-
def __init__(self, func: Callable[..., Any], name: str = None) -> None:
|
|
17
|
-
self.wrapped_func = func
|
|
18
|
-
self.name = name
|
|
19
|
-
self.__doc__ = getattr(func, "__doc__")
|
|
20
|
-
|
|
21
|
-
def __get__(self, instance: Any, cls: Any = None) -> Any:
|
|
22
|
-
"""
|
|
23
|
-
Call the function and put the return value in instance.__dict__ so that
|
|
24
|
-
subsequent attribute access on the instance returns the cached value
|
|
25
|
-
instead of calling cached_property.__get__().
|
|
26
|
-
"""
|
|
27
|
-
if instance is None:
|
|
28
|
-
return self
|
|
29
|
-
res = instance.__dict__[self.name] = self.func(instance)
|
|
30
|
-
return res
|
|
31
|
-
|
|
32
|
-
def __set_name__(self, cls: Any = None, name: str = None) -> None:
|
|
33
|
-
"""
|
|
34
|
-
The function is called at the time the cls class is created.
|
|
35
|
-
The descriptor would be assigned to name.
|
|
36
|
-
"""
|
|
37
|
-
if self.name is None:
|
|
38
|
-
self.name = name
|
|
39
|
-
self.func = self.wrapped_func
|
|
40
|
-
if name != self.name:
|
|
41
|
-
raise TypeError(
|
|
42
|
-
"Unable to assign cached_property for two different names "
|
|
43
|
-
f"(%{self.name} and {name})."
|
|
44
|
-
)
|
ethpm/_utils/chains.py
DELETED
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
import re
|
|
2
|
-
from typing import (
|
|
3
|
-
TYPE_CHECKING,
|
|
4
|
-
Any,
|
|
5
|
-
Tuple,
|
|
6
|
-
)
|
|
7
|
-
from urllib import (
|
|
8
|
-
parse,
|
|
9
|
-
)
|
|
10
|
-
|
|
11
|
-
from eth_typing import (
|
|
12
|
-
URI,
|
|
13
|
-
BlockNumber,
|
|
14
|
-
HexStr,
|
|
15
|
-
)
|
|
16
|
-
from eth_utils import (
|
|
17
|
-
add_0x_prefix,
|
|
18
|
-
is_integer,
|
|
19
|
-
remove_0x_prefix,
|
|
20
|
-
)
|
|
21
|
-
from hexbytes import (
|
|
22
|
-
HexBytes,
|
|
23
|
-
)
|
|
24
|
-
|
|
25
|
-
from ethpm.constants import (
|
|
26
|
-
SUPPORTED_CHAIN_IDS,
|
|
27
|
-
)
|
|
28
|
-
|
|
29
|
-
if TYPE_CHECKING:
|
|
30
|
-
from web3 import Web3 # noqa: F401
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
def get_genesis_block_hash(w3: "Web3") -> HexBytes:
|
|
34
|
-
return w3.eth.get_block(BlockNumber(0))["hash"]
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
BLOCK = "block"
|
|
38
|
-
|
|
39
|
-
BIP122_URL_REGEX = (
|
|
40
|
-
"^"
|
|
41
|
-
"blockchain://"
|
|
42
|
-
"(?P<chain_id>[a-zA-Z0-9]{64})"
|
|
43
|
-
"/"
|
|
44
|
-
"(?P<resource_type>block|transaction)"
|
|
45
|
-
"/"
|
|
46
|
-
"(?P<resource_hash>[a-zA-Z0-9]{64})"
|
|
47
|
-
"$"
|
|
48
|
-
)
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
def is_BIP122_uri(value: URI) -> bool:
|
|
52
|
-
return bool(re.match(BIP122_URL_REGEX, value))
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
def parse_BIP122_uri(blockchain_uri: URI) -> Tuple[HexStr, str, HexStr]:
|
|
56
|
-
match = re.match(BIP122_URL_REGEX, blockchain_uri)
|
|
57
|
-
if match is None:
|
|
58
|
-
raise ValueError(f"Invalid URI format: '{blockchain_uri}'")
|
|
59
|
-
chain_id, resource_type, resource_hash = match.groups()
|
|
60
|
-
return (
|
|
61
|
-
add_0x_prefix(HexStr(chain_id)),
|
|
62
|
-
resource_type,
|
|
63
|
-
add_0x_prefix(HexStr(resource_hash)),
|
|
64
|
-
)
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
def is_BIP122_block_uri(value: URI) -> bool:
|
|
68
|
-
if not is_BIP122_uri(value):
|
|
69
|
-
return False
|
|
70
|
-
_, resource_type, _ = parse_BIP122_uri(value)
|
|
71
|
-
return resource_type == BLOCK
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
BLOCK_OR_TRANSACTION_HASH_REGEX = "^(?:0x)?[a-zA-Z0-9]{64}$"
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
def is_block_or_transaction_hash(value: str) -> bool:
|
|
78
|
-
return bool(re.match(BLOCK_OR_TRANSACTION_HASH_REGEX, value))
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
def create_BIP122_uri(
|
|
82
|
-
chain_id: HexStr, resource_type: str, resource_identifier: HexStr
|
|
83
|
-
) -> URI:
|
|
84
|
-
"""
|
|
85
|
-
See: https://github.com/bitcoin/bips/blob/master/bip-0122.mediawiki
|
|
86
|
-
"""
|
|
87
|
-
if resource_type != BLOCK:
|
|
88
|
-
raise ValueError("Invalid resource_type. Must be one of 'block'")
|
|
89
|
-
elif not is_block_or_transaction_hash(resource_identifier):
|
|
90
|
-
raise ValueError(
|
|
91
|
-
"Invalid resource_identifier. Must be a hex encoded 32 byte value"
|
|
92
|
-
)
|
|
93
|
-
elif not is_block_or_transaction_hash(chain_id):
|
|
94
|
-
raise ValueError("Invalid chain_id. Must be a hex encoded 32 byte value")
|
|
95
|
-
|
|
96
|
-
return URI(
|
|
97
|
-
parse.urlunsplit(
|
|
98
|
-
[
|
|
99
|
-
"blockchain",
|
|
100
|
-
remove_0x_prefix(chain_id),
|
|
101
|
-
f"{resource_type}/{remove_0x_prefix(resource_identifier)}",
|
|
102
|
-
"",
|
|
103
|
-
"",
|
|
104
|
-
]
|
|
105
|
-
)
|
|
106
|
-
)
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
def create_block_uri(chain_id: HexStr, block_identifier: HexStr) -> URI:
|
|
110
|
-
return create_BIP122_uri(chain_id, "block", remove_0x_prefix(block_identifier))
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
def is_supported_chain_id(chain_id: Any) -> bool:
|
|
114
|
-
if not is_integer(chain_id):
|
|
115
|
-
return False
|
|
116
|
-
|
|
117
|
-
if chain_id not in SUPPORTED_CHAIN_IDS.keys():
|
|
118
|
-
return False
|
|
119
|
-
return True
|
ethpm/_utils/contract.py
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
from typing import (
|
|
2
|
-
Any,
|
|
3
|
-
Dict,
|
|
4
|
-
Generator,
|
|
5
|
-
Tuple,
|
|
6
|
-
)
|
|
7
|
-
|
|
8
|
-
from eth_utils import (
|
|
9
|
-
to_dict,
|
|
10
|
-
)
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
@to_dict
|
|
14
|
-
def generate_contract_factory_kwargs(
|
|
15
|
-
contract_data: Dict[str, Any]
|
|
16
|
-
) -> Generator[Tuple[str, Any], None, None]:
|
|
17
|
-
"""
|
|
18
|
-
Build a dictionary of kwargs to be passed into contract factory.
|
|
19
|
-
"""
|
|
20
|
-
if "abi" in contract_data:
|
|
21
|
-
yield "abi", contract_data["abi"]
|
|
22
|
-
|
|
23
|
-
if "deploymentBytecode" in contract_data:
|
|
24
|
-
yield "bytecode", contract_data["deploymentBytecode"]["bytecode"]
|
|
25
|
-
if "linkReferences" in contract_data["deploymentBytecode"]:
|
|
26
|
-
yield "unlinked_references", tuple(
|
|
27
|
-
contract_data["deploymentBytecode"]["linkReferences"]
|
|
28
|
-
)
|
|
29
|
-
|
|
30
|
-
if "runtimeBytecode" in contract_data:
|
|
31
|
-
yield "bytecode_runtime", contract_data["runtimeBytecode"]["bytecode"]
|
|
32
|
-
if "linkReferences" in contract_data["runtimeBytecode"]:
|
|
33
|
-
yield "linked_references", tuple(
|
|
34
|
-
contract_data["runtimeBytecode"]["linkReferences"]
|
|
35
|
-
)
|