Skip to content

Comments

fix: remove stale NonceTooLow txs from retry loop#210

Merged
qj0r9j0vc2 merged 1 commit intomainfrom
qj0r9j0vc2/fix-eth-call-gas-cap
Feb 20, 2026
Merged

fix: remove stale NonceTooLow txs from retry loop#210
qj0r9j0vc2 merged 1 commit intomainfrom
qj0r9j0vc2/fix-eth-call-gas-cap

Conversation

@qj0r9j0vc2
Copy link
Member

Summary

  • Track permanently-skipped (NonceTooLow) transaction hashes in ExecutionResult
  • Remove them from the RPC pending map after block execution
  • Prevents infinite retry loop where stale transactions cycle through consensus and execution repeatedly

Problem

After block execution, retry_pending() re-sends all unexecuted pending transactions to the Worker channel for rebatching. However, NonceTooLow transactions can never succeed (their nonce has already been used), so they cycle forever: Worker → Batch → Consensus → Execution (NonceTooLow) → retry → Worker → ...

This produces blocks where all transactions are skipped, wasting consensus bandwidth and producing empty blocks.

Changes

  • ExecutionResult.skipped_tx_hashes — new field tracking NonceTooLow tx hashes
  • engine.rs — collects skipped hashes during process_transactions
  • BlockExecutionResult — propagates skipped hashes through execution bridge
  • node.rs — removes skipped txs from pending map and excludes from retry

Test plan

  • cargo check passes
  • cargo test -p cipherbft-execution -p cipherd passes
  • Verify under load test that NonceTooLow transactions no longer cycle

@qj0r9j0vc2 qj0r9j0vc2 self-assigned this Feb 20, 2026
@qj0r9j0vc2 qj0r9j0vc2 merged commit 677c8a4 into main Feb 20, 2026
20 checks passed
@qj0r9j0vc2 qj0r9j0vc2 deleted the qj0r9j0vc2/fix-eth-call-gas-cap branch February 20, 2026 23:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant