Skip to content

Commit 46d0d2a

Browse files
authored
fix: precommit mypy (#2017)
1 parent e5e30e6 commit 46d0d2a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

express_relay/sdk/python/express_relay/searcher/examples/simple_searcher.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import argparse
22
import asyncio
33
import logging
4+
import typing
5+
46
from eth_account.account import Account
57
from secrets import randbits
68

@@ -16,6 +18,7 @@
1618
Bytes32,
1719
BidStatus,
1820
BidStatusUpdate,
21+
OpportunityEvm,
1922
)
2023

2124
logger = logging.getLogger(__name__)
@@ -40,7 +43,7 @@ def __init__(
4043

4144
def assess_opportunity(
4245
self,
43-
opp: Opportunity,
46+
opp: OpportunityEvm,
4447
) -> BidEvm | None:
4548
"""
4649
Assesses whether an opportunity is worth executing; if so, returns a Bid object.
@@ -72,7 +75,7 @@ async def opportunity_callback(self, opp: Opportunity):
7275
Args:
7376
opp: An object representing a single opportunity.
7477
"""
75-
bid = self.assess_opportunity(opp)
78+
bid = self.assess_opportunity(typing.cast(OpportunityEvm, opp))
7679
if bid:
7780
try:
7881
await self.client.submit_bid(bid)

0 commit comments

Comments
 (0)