faster-eth-utils 2.3.1__cp311-cp311-win32.whl → 5.3.23__cp311-cp311-win32.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.
Potentially problematic release.
This version of faster-eth-utils might be problematic. Click here for more details.
- faster_eth_utils/__init__.py +54 -17
- faster_eth_utils/__json/eth_networks.json +1 -0
- faster_eth_utils/__main__.py +3 -1
- faster_eth_utils/abi.cp311-win32.pyd +0 -0
- faster_eth_utils/abi.py +840 -37
- faster_eth_utils/address.cp311-win32.pyd +0 -0
- faster_eth_utils/address.py +54 -66
- faster_eth_utils/applicators.cp311-win32.pyd +0 -0
- faster_eth_utils/applicators.py +126 -71
- faster_eth_utils/conversions.cp311-win32.pyd +0 -0
- faster_eth_utils/conversions.py +57 -30
- faster_eth_utils/crypto.cp311-win32.pyd +0 -0
- faster_eth_utils/crypto.py +11 -6
- faster_eth_utils/currency.cp311-win32.pyd +0 -0
- faster_eth_utils/currency.py +74 -33
- faster_eth_utils/curried/__init__.py +110 -89
- faster_eth_utils/debug.cp311-win32.pyd +0 -0
- faster_eth_utils/debug.py +3 -3
- faster_eth_utils/decorators.cp311-win32.pyd +0 -0
- faster_eth_utils/decorators.py +73 -24
- faster_eth_utils/encoding.cp311-win32.pyd +0 -0
- faster_eth_utils/encoding.py +1 -1
- faster_eth_utils/exceptions.cp311-win32.pyd +0 -0
- faster_eth_utils/exceptions.py +8 -3
- faster_eth_utils/functional.cp311-win32.pyd +0 -0
- faster_eth_utils/functional.py +42 -28
- faster_eth_utils/hexadecimal.cp311-win32.pyd +0 -0
- faster_eth_utils/hexadecimal.py +34 -26
- faster_eth_utils/humanize.cp311-win32.pyd +0 -0
- faster_eth_utils/humanize.py +55 -27
- faster_eth_utils/logging.py +65 -64
- faster_eth_utils/module_loading.cp311-win32.pyd +0 -0
- faster_eth_utils/module_loading.py +8 -7
- faster_eth_utils/network.cp311-win32.pyd +0 -0
- faster_eth_utils/network.py +25 -14
- faster_eth_utils/numeric.cp311-win32.pyd +0 -0
- faster_eth_utils/numeric.py +11 -4
- faster_eth_utils/pydantic.py +99 -0
- faster_eth_utils/toolz.cp311-win32.pyd +0 -0
- faster_eth_utils/toolz.py +82 -152
- faster_eth_utils/types.cp311-win32.pyd +0 -0
- faster_eth_utils/types.py +34 -21
- faster_eth_utils/typing/misc.py +3 -1
- faster_eth_utils/units.cp311-win32.pyd +0 -0
- faster_eth_utils-5.3.23.dist-info/METADATA +192 -0
- faster_eth_utils-5.3.23.dist-info/RECORD +53 -0
- {faster_eth_utils-2.3.1.dist-info → faster_eth_utils-5.3.23.dist-info}/licenses/LICENSE +1 -1
- faster_eth_utils-5.3.23.dist-info/top_level.txt +3 -0
- faster_eth_utils__mypyc.cp311-win32.pyd +0 -0
- bce0bfc64ce5e845ec4a__mypyc.cp311-win32.pyd +0 -0
- faster_eth_utils-2.3.1.dist-info/METADATA +0 -160
- faster_eth_utils-2.3.1.dist-info/RECORD +0 -45
- faster_eth_utils-2.3.1.dist-info/top_level.txt +0 -3
- {faster_eth_utils-2.3.1.dist-info → faster_eth_utils-5.3.23.dist-info}/WHEEL +0 -0
faster_eth_utils/__init__.py
CHANGED
|
@@ -1,18 +1,24 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
# Python 3.7
|
|
5
|
-
def __version(package_name: str) -> str: # type: ignore
|
|
6
|
-
from pkg_resources import get_distribution
|
|
7
|
-
|
|
8
|
-
return get_distribution(package_name).version
|
|
9
|
-
|
|
1
|
+
from importlib.metadata import (
|
|
2
|
+
version as __version,
|
|
3
|
+
)
|
|
10
4
|
|
|
11
5
|
from .abi import (
|
|
6
|
+
abi_to_signature,
|
|
7
|
+
collapse_if_tuple,
|
|
12
8
|
event_abi_to_log_topic,
|
|
13
9
|
event_signature_to_log_topic,
|
|
10
|
+
filter_abi_by_name,
|
|
11
|
+
filter_abi_by_type,
|
|
14
12
|
function_abi_to_4byte_selector,
|
|
15
13
|
function_signature_to_4byte_selector,
|
|
14
|
+
get_abi_input_names,
|
|
15
|
+
get_abi_input_types,
|
|
16
|
+
get_abi_output_names,
|
|
17
|
+
get_abi_output_types,
|
|
18
|
+
get_aligned_abi_inputs,
|
|
19
|
+
get_all_event_abis,
|
|
20
|
+
get_all_function_abis,
|
|
21
|
+
get_normalized_abi_inputs,
|
|
16
22
|
)
|
|
17
23
|
from .address import (
|
|
18
24
|
is_address,
|
|
@@ -37,12 +43,35 @@ from .applicators import (
|
|
|
37
43
|
apply_one_of_formatters,
|
|
38
44
|
combine_argument_formatters,
|
|
39
45
|
)
|
|
40
|
-
from .conversions import
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
+
from .conversions import (
|
|
47
|
+
hexstr_if_str,
|
|
48
|
+
text_if_str,
|
|
49
|
+
to_bytes,
|
|
50
|
+
to_hex,
|
|
51
|
+
to_int,
|
|
52
|
+
to_text,
|
|
53
|
+
)
|
|
54
|
+
from .crypto import (
|
|
55
|
+
keccak,
|
|
56
|
+
)
|
|
57
|
+
from .currency import (
|
|
58
|
+
denoms,
|
|
59
|
+
from_wei,
|
|
60
|
+
from_wei_decimals,
|
|
61
|
+
to_wei,
|
|
62
|
+
to_wei_decimals,
|
|
63
|
+
)
|
|
64
|
+
from .decorators import (
|
|
65
|
+
combomethod,
|
|
66
|
+
replace_exceptions,
|
|
67
|
+
)
|
|
68
|
+
from .encoding import (
|
|
69
|
+
big_endian_to_int,
|
|
70
|
+
int_to_big_endian,
|
|
71
|
+
)
|
|
72
|
+
from .exceptions import (
|
|
73
|
+
ValidationError,
|
|
74
|
+
)
|
|
46
75
|
from .functional import (
|
|
47
76
|
apply_to_return_value,
|
|
48
77
|
flatten_return,
|
|
@@ -66,6 +95,7 @@ from .hexadecimal import (
|
|
|
66
95
|
from .humanize import (
|
|
67
96
|
humanize_bytes,
|
|
68
97
|
humanize_hash,
|
|
98
|
+
humanize_hexstr,
|
|
69
99
|
humanize_integer_sequence,
|
|
70
100
|
humanize_ipfs_uri,
|
|
71
101
|
humanize_seconds,
|
|
@@ -82,14 +112,21 @@ from .logging import (
|
|
|
82
112
|
get_logger,
|
|
83
113
|
setup_DEBUG2_logging,
|
|
84
114
|
)
|
|
85
|
-
from .module_loading import
|
|
115
|
+
from .module_loading import (
|
|
116
|
+
import_string,
|
|
117
|
+
)
|
|
86
118
|
from .network import (
|
|
87
119
|
Network,
|
|
88
120
|
name_from_chain_id,
|
|
89
121
|
network_from_chain_id,
|
|
90
122
|
short_name_from_chain_id,
|
|
91
123
|
)
|
|
92
|
-
from .numeric import
|
|
124
|
+
from .numeric import (
|
|
125
|
+
clamp,
|
|
126
|
+
)
|
|
127
|
+
from .pydantic import (
|
|
128
|
+
CamelModel,
|
|
129
|
+
)
|
|
93
130
|
from .types import (
|
|
94
131
|
is_boolean,
|
|
95
132
|
is_bytes,
|