node icon indicating copy to clipboard operation
node copied to clipboard

Eliminate edge case where a CCTX is still pending but the associated outbound nonce is not included in pendingNonces

Open CryptoFewka opened this issue 7 months ago • 0 comments

Is your feature request related to a problem? Please describe. Currently it is possible to reach an edge case where an outbound tracker is not created for a given CCTX, despite the outbound TX being emitted on to the connected chain. Subsequent transactions will also be emitted because the chain's nonce has actually advanced on the connected chain. ZetaClientd properly infers this when it observes a subsequent CCTX, and updates low_nonce accordingly, but low_nonce seems to also be used for returning a list of pending CCTX from the pendingCctx endpoint. This leads to a case where an pending CCTX is not returned from the pendingCctx endpoint despite it still officially being marked as pending.

Describe the solution you'd like Update /zeta-chain/crosschain/pendingCctx and /zeta-chain/crosschain/pendingCctxWithinRateLimit to return all pending CCTX, even if their associated outbound nonce is below the value currently held for low_nonce.

Describe alternatives you've considered Adding a lookback window based off of low_nonce, which monitoring investigates hunting for any CCTX which are still pending but are not returned by /zeta-chain/crosschain/pendingCctxWithinRateLimit.

Motivation and Context We want to ensure that all CCTX are completed correctly on chain when they actually have been, and specifically that any which lack an outbound tracker receive one.

CryptoFewka avatar May 13 '25 18:05 CryptoFewka