Skip to content

Commit 430d987

Browse files
committed
fix: only retry the /v2/pox endpoint if it returns an older cycle
It's okay if it returns a higher cycle than expected.
1 parent 2082113 commit 430d987

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

stacks-signer/src/runloop.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ impl RunLoop {
296296
.stacks_client
297297
.get_current_reward_cycle_info()
298298
.map_err(backoff::Error::transient)?;
299-
if info.reward_cycle != block_reward_cycle {
299+
if info.reward_cycle < block_reward_cycle {
300300
// If the stacks-node is still processing the burn block, the /v2/pox endpoint
301301
// may return the previous reward cycle. In this case, we should retry.
302302
return Err(backoff::Error::transient(ClientError::InvalidResponse(

0 commit comments

Comments
 (0)