File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 1
1
from eth_typing import ChecksumAddress
2
+ from hexbytes import HexBytes
2
3
from web3 import Web3
3
4
from web3 .types import Wei
4
5
@@ -52,10 +53,10 @@ async def _fetch_harvest_params_from_ipfs(
52
53
reward = Wei (vault_data ['consensus_reward' ])
53
54
54
55
return HarvestParams (
55
- rewards_root = rewards_root ,
56
+ rewards_root = HexBytes ( rewards_root ) ,
56
57
reward = reward ,
57
58
unlocked_mev_reward = unlocked_mev_reward ,
58
- proof = [Web3 .to_bytes (hexstr = x ) for x in vault_data ['proof' ]],
59
+ proof = [HexBytes ( Web3 .to_bytes (hexstr = x ) ) for x in vault_data ['proof' ]],
59
60
)
60
61
61
62
return None
Original file line number Diff line number Diff line change 1
1
from dataclasses import dataclass
2
2
3
+ from hexbytes import HexBytes
3
4
from web3 .types import Wei
4
5
5
6
@@ -11,10 +12,10 @@ class RewardVoteInfo:
11
12
12
13
@dataclass
13
14
class HarvestParams :
14
- rewards_root : bytes
15
+ rewards_root : HexBytes
15
16
reward : Wei
16
17
unlocked_mev_reward : Wei
17
- proof : list [bytes ]
18
+ proof : list [HexBytes ]
18
19
19
20
20
21
@dataclass
You can’t perform that action at this time.
0 commit comments