Updated DevUtils contract artifact (#2358)
* Add updated DevUtils contract artifact New contract methods were added in #2321, but this artifact was not updated. * fix for breaking change in eth_utils
This commit is contained in:
parent
ed8340affa
commit
daa593d225
74
packages/contract-artifacts/artifacts/DevUtils.json
generated
74
packages/contract-artifacts/artifacts/DevUtils.json
generated
File diff suppressed because one or more lines are too long
@ -182,6 +182,7 @@ setup(
|
||||
"deprecated",
|
||||
"web3",
|
||||
"eth-abi",
|
||||
"eth_typing",
|
||||
"eth_utils",
|
||||
"mypy_extensions",
|
||||
],
|
||||
|
@ -23,6 +23,7 @@ from typing import cast, Tuple, Union
|
||||
from pkg_resources import resource_string
|
||||
from mypy_extensions import TypedDict
|
||||
|
||||
from eth_typing import HexStr
|
||||
from eth_utils import keccak, remove_0x_prefix, to_bytes, to_checksum_address
|
||||
from web3 import Web3
|
||||
import web3.exceptions
|
||||
@ -217,9 +218,9 @@ def is_valid_signature(
|
||||
)
|
||||
).exchange,
|
||||
).is_valid_hash_signature.call(
|
||||
bytes.fromhex(remove_0x_prefix(data)),
|
||||
bytes.fromhex(remove_0x_prefix(HexStr(data))),
|
||||
to_checksum_address(signer_address),
|
||||
bytes.fromhex(remove_0x_prefix(signature)),
|
||||
bytes.fromhex(remove_0x_prefix(HexStr(signature))),
|
||||
)
|
||||
|
||||
|
||||
@ -393,5 +394,5 @@ def sign_hash_to_bytes(
|
||||
'1b117902c86dfb95fe0d1badd983ee166ad259b27acb220174cbb4460d872871137feabdfe76e05924b484789f79af4ee7fa29ec006cedce1bbf369320d034e10b03'
|
||||
""" # noqa: E501 (line too long)
|
||||
return remove_0x_prefix(
|
||||
sign_hash(web3_or_provider, signer_address, hash_hex)
|
||||
HexStr(sign_hash(web3_or_provider, signer_address, hash_hex))
|
||||
).encode(encoding="utf_8")
|
||||
|
Loading…
x
Reference in New Issue
Block a user