{"record":{"id":"4d2234665897d9ab","repo":"nautechsystems/nautilus_trader","slug":"execution-intent-has-duplicate-authenticated-tr","errorCode":null,"errorMessage":"Execution intent {} has duplicate authenticated transaction hash {}","messagePattern":"Execution intent (.+?) has duplicate authenticated transaction hash (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/adapters/blockchain/src/execution/client.rs","lineNumber":1251,"sourceCode":"                format!(\n                    \"Execution intent {} has invalid transaction hash {}\",\n                    intent.id, hash.transaction_hash\n                )\n            })?;\n            anyhow::ensure!(\n                authenticated_payloads\n                    .insert(authenticated_hash, raw_transaction.clone())\n                    .is_none(),\n                \"Execution intent {} has duplicate authenticated transaction hash {}\",\n                intent.id,\n                hash.transaction_hash\n            );\n\n            if hash.id == current.id {\n                current_payload = Some(raw_transaction);\n            }\n        }\n        anyhow::ensure!(\n            !authenticated_payloads.is_empty(),\n            \"Execution intent {} has no persisted signed transaction bytes\",\n            intent.id\n        );\n\n        if intent.status == \"broadcast\" {\n            anyhow::ensure!(\n                current_payload.is_some(),\n                \"Broadcast execution intent {} has no persisted signed transaction bytes\",\n                intent.id\n            );\n        }\n\n        if intent.status == \"signed\" {\n            anyhow::bail!(\n                \"Execution intent {} has a signed transaction {} that was not authorized for broadcast; its nonce remains reserved pending explicit recovery\",\n                intent.id,\n                tx_hash","sourceCodeStart":1233,"sourceCodeEnd":1269,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/18893faf8b356be3320add8de2f861b0b647cf06/crates/adapters/blockchain/src/execution/client.rs#L1233-L1269","documentation":"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.","triggerScenarios":"connect() -> reconcile_unresolved_execution(): authenticated_payloads.insert(authenticated_hash, ...) returns Some, meaning the hash was already inserted for this intent.","commonSituations":"Duplicate rows inserted by a retrying writer; DB restored from overlapping backups; crash between insert and deduplication.","solutions":["Deduplicate the execution transactions table for that intent_id, keeping one canonical row","Remove the duplicate rows and re-run recovery","Add/verify a uniqueness constraint on (intent_id, transaction_hash) in the database"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"let mut seen = std::collections::HashSet::new();\nfor h in &hashes {\n    if !seen.insert(&h.transaction_hash) {\n        // deduplicate rows for this intent before recovery\n    }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Add a unique index on (intent_id, transaction_hash)","Make transaction-row insertion idempotent","Audit backup-restore procedures for overlapping data"],"tags":["blockchain","database","deduplication","recovery"],"backgroundTag":"internal-invariant-violation","analyzedSha":"18893faf8b356be3320add8de2f861b0b647cf06","analyzedAt":"2026-09-08T20:49:34.690Z","contentChangedAt":"2026-09-08T20:49:34.690Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}