File tree Expand file tree Collapse file tree 3 files changed +8
-2
lines changed
async_substrate_interface Expand file tree Collapse file tree 3 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 38
38
SubstrateRequestException ,
39
39
ExtrinsicNotFound ,
40
40
BlockNotFound ,
41
+ MaxRetriesExceeded ,
41
42
)
42
43
from async_substrate_interface .types import (
43
44
ScaleObj ,
@@ -1914,7 +1915,7 @@ async def _make_rpc_request(
1914
1915
logger .warning (
1915
1916
f"Timed out waiting for RPC requests { attempt } times. Exiting."
1916
1917
)
1917
- raise SubstrateRequestException ("Max retries reached." )
1918
+ raise MaxRetriesExceeded ("Max retries reached." )
1918
1919
else :
1919
1920
self .ws .last_received = time .time ()
1920
1921
await self .ws .connect (force = True )
Original file line number Diff line number Diff line change @@ -8,6 +8,10 @@ class SubstrateRequestException(Exception):
8
8
pass
9
9
10
10
11
+ class MaxRetriesExceeded (SubstrateRequestException ):
12
+ pass
13
+
14
+
11
15
class StorageFunctionNotFound (ValueError ):
12
16
pass
13
17
Original file line number Diff line number Diff line change 20
20
ExtrinsicNotFound ,
21
21
SubstrateRequestException ,
22
22
BlockNotFound ,
23
+ MaxRetriesExceeded ,
23
24
)
24
25
from async_substrate_interface .types import (
25
26
SubstrateMixin ,
@@ -1615,7 +1616,7 @@ def _make_rpc_request(
1615
1616
logger .warning (
1616
1617
f"Timed out waiting for RPC requests { attempt } times. Exiting."
1617
1618
)
1618
- raise SubstrateRequestException ("Max retries reached." )
1619
+ raise MaxRetriesExceeded ("Max retries reached." )
1619
1620
else :
1620
1621
return self ._make_rpc_request (
1621
1622
payloads ,
You can’t perform that action at this time.
0 commit comments