Skip to content

Commit 04253d0

Browse files
committed
Fix lint
1 parent ca234d3 commit 04253d0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

examples/evm_erc20.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,8 @@ class FinalizeEvmContractAction(TypedDict):
267267
creation_nonce = 0
268268

269269
if SHOULD_LINK_CONTRACT:
270-
assert contract_address is not None
270+
if contract_address is None:
271+
raise Exception("contract address cannot be None")
271272
action = {
272273
"type": "spotDeploy",
273274
"requestEvmContract": {
@@ -284,7 +285,7 @@ class FinalizeEvmContractAction(TypedDict):
284285
"signature": signature,
285286
"vaultAddress": None,
286287
}
287-
response = requests.post(constants.TESTNET_API_URL + "/exchange", json=payload)
288+
response = requests.post(constants.TESTNET_API_URL + "/exchange", json=payload, timeout=10)
288289
print(response.json())
289290

290291
use_create_finalization = True
@@ -305,5 +306,5 @@ class FinalizeEvmContractAction(TypedDict):
305306
"signature": signature,
306307
"vaultAddress": None,
307308
}
308-
response = requests.post(constants.TESTNET_API_URL + "/exchange", json=payload)
309+
response = requests.post(constants.TESTNET_API_URL + "/exchange", json=payload, timeout=10)
309310
print(response.json())

0 commit comments

Comments
 (0)