@@ -89,9 +89,7 @@ const (
89
89
queryTimeout = 5 * time .Second
90
90
blockResultsQueryTimeout = 2 * time .Minute
91
91
latestHeightQueryRetryDelay = 1 * time .Second
92
- clientStateQueryRetryDelay = 1 * time .Second
93
92
latestHeightQueryRetries = 5
94
- clientStateQueryRetries = 5
95
93
96
94
// TODO: review transfer to providerConfig
97
95
defaultMinQueryLoopDuration = 1 * time .Second
@@ -563,7 +561,6 @@ func (ccp *WasmChainProcessor) queryCycle(ctx context.Context, persistence *quer
563
561
ccp .handleMessage (ctx , m , ibcMessagesCache )
564
562
}
565
563
}
566
-
567
564
newLatestQueriedBlock = i
568
565
}
569
566
if newLatestQueriedBlock == persistence .latestQueriedBlock {
@@ -581,30 +578,15 @@ func (ccp *WasmChainProcessor) queryCycle(ctx context.Context, persistence *quer
581
578
}
582
579
583
580
for _ , pp := range ccp .pathProcessors {
584
- var clientState provider.ClientState
585
- var clientID string
586
- retry .Do (func () error {
587
- clientID = pp .RelevantClientID (chainID )
588
- clientState , err = ccp .clientState (ctx , clientID )
589
- return err
590
- }, retry .Context (ctx ), retry .Attempts (clientStateQueryRetries ),
591
- retry .Delay (clientStateQueryRetryDelay ),
592
- retry .OnRetry (func (n uint , err error ) {
593
- ccp .log .Error (
594
- "Error fetching client state" ,
595
- zap .Uint ("attempt" , n + 1 ),
596
- zap .Uint ("max_attempts" , clientStateQueryRetries ),
597
- zap .Error (err ),
598
- )
599
- }))
600
- if clientState .ClientID == "" {
601
- ccp .log .Error (
602
- "Error fetching client state after max retries" ,
581
+ clientID := pp .RelevantClientID (chainID )
582
+ clientState , err := ccp .clientState (ctx , clientID )
583
+ if err != nil {
584
+ ccp .log .Error ("Error fetching client state" ,
585
+ zap .String ("client_id" , clientID ),
603
586
zap .Int64 ("latest_queried_block" , newLatestQueriedBlock ),
604
587
zap .Int64 ("last_queried_block" , persistence .latestQueriedBlock ),
605
588
zap .Error (err ),
606
589
)
607
- continue
608
590
}
609
591
610
592
pp .HandleNewData (chainID , processor.ChainProcessorCacheData {
0 commit comments