nautechsystems/nautilus_trader · error

Execution intent {} has duplicate authenticated transaction

Error message

Execution intent {} has duplicate authenticated transaction hash {}

What it means

During reconciliation, two transaction hashes for the same execution intent authenticated to the same B256 value; the intent carries duplicate/mutually conflicting signed transactions, which would be ambiguous to resolve, so the ensure guard rejects the state.

Source

Thrown at crates/adapters/blockchain/src/execution/client.rs:1251

                format!(
                    "Execution intent {} has invalid transaction hash {}",
                    intent.id, hash.transaction_hash
                )
            })?;
            anyhow::ensure!(
                authenticated_payloads
                    .insert(authenticated_hash, raw_transaction.clone())
                    .is_none(),
                "Execution intent {} has duplicate authenticated transaction hash {}",
                intent.id,
                hash.transaction_hash
            );

            if hash.id == current.id {
                current_payload = Some(raw_transaction);
            }
        }
        anyhow::ensure!(
            !authenticated_payloads.is_empty(),
            "Execution intent {} has no persisted signed transaction bytes",
            intent.id
        );

        if intent.status == "broadcast" {
            anyhow::ensure!(
                current_payload.is_some(),
                "Broadcast execution intent {} has no persisted signed transaction bytes",
                intent.id
            );
        }

        if intent.status == "signed" {
            anyhow::bail!(
                "Execution intent {} has a signed transaction {} that was not authorized for broadcast; its nonce remains reserved pending explicit recovery",
                intent.id,
                tx_hash

View on GitHub (pinned to 18893faf8b)

Solutions

  1. Deduplicate the execution transactions table for that intent_id, keeping one canonical row
  2. Remove the duplicate rows and re-run recovery
  3. Add/verify a uniqueness constraint on (intent_id, transaction_hash) in the database
Defensive patterns

Strategy: validation

Validate before calling

let mut seen = std::collections::HashSet::new();
for h in &hashes {
    if !seen.insert(&h.transaction_hash) {
        // deduplicate rows for this intent before recovery
    }
}

Prevention

When it happens

Trigger: connect() -> reconcile_unresolved_execution(): authenticated_payloads.insert(authenticated_hash, ...) returns Some, meaning the hash was already inserted for this intent.

Common situations: Duplicate rows inserted by a retrying writer; DB restored from overlapping backups; crash between insert and deduplication.

Understand the failure class

Background: "This is a bug, please report it": internal invariant violations, unreachable panics, and SNH errors explained — this error's family across 47 libraries.

Related errors


AI-assisted analysis of nautechsystems/nautilus_trader@18893faf8b (2026-09-08). Data as JSON: /api/errors/4d2234665897d9ab. Report an issue: GitHub.