nautechsystems/nautilus_trader · error
Active verified-action intent was not found
Error message
Active verified-action intent was not found
What it means
Thrown when no active execution intent row matches the batch's intent_id, chain_id, and wallet_address. Verified actions may only be appended to an intent that exists and is still active; a missing row means the intent never existed, was already completed/finalized, or the identifying fields are wrong.
Source
Thrown at crates/adapters/blockchain/src/cache/database.rs:6100
anyhow::ensure!(
manifest_version == batch.manifest_version && manifest_digest == batch.manifest_digest,
"Verified action manifest identity changed"
);
let intent_nonce = sqlx::query_scalar::<_, Option<i64>>(
"
SELECT nonce
FROM execution_intent
WHERE id = $1 AND chain_id = $2 AND wallet_address = $3 AND active
FOR UPDATE
",
)
.bind(batch.intent_id)
.bind(chain_id)
.bind(batch.wallet_address)
.fetch_optional(&mut *transaction)
.await
.map_err(|e| anyhow::anyhow!("Failed to lock intent for verified action: {e}"))?
.ok_or_else(|| anyhow::anyhow!("Active verified-action intent was not found"))?;
anyhow::ensure!(
intent_nonce == Some(nonce),
"Verified action nonce does not match the active intent"
);
let attempt = sqlx::query_scalar::<_, i64>(
"
SELECT COUNT(*)
FROM execution_verification_decision
WHERE intent_id = $1 AND decision_class = $2
",
)
.bind(batch.intent_id)
.bind(batch.decision_class)
.fetch_one(&mut *transaction)
.await
.map_err(|e| anyhow::anyhow!("Failed to number verified action evidence: {e}"))?;
for (index, decision) in batch.decisions.iter().enumerate() {View on GitHub (pinned to 18893faf8b)
Solutions
- Confirm the intent exists and is active by querying it with the same intent_id, chain_id, and wallet_address.
- Create the intent first (the intent-creation flow) before attempting to record a verified action against it.
- Check whether the intent already completed — treat this as a duplicate submission rather than retrying.
- Validate the wallet_address format/casing matches how the intent was stored.
Example fix
// before: record action for possibly unknown intent
record_execution_verification_batch(&db, &batch).await?;
// after: check active intent first
let active = sqlx::query_scalar::<_, i64>("SELECT 1 FROM execution_intent WHERE intent_id = $1 AND chain_id = $2 AND wallet_address = $3 AND status = 'active'")
.bind(&batch.intent_id).bind(chain_id).bind(batch.wallet_address).fetch_optional(&db).await?;
anyhow::ensure!(active.is_some(), "intent {} not active", batch.intent_id);
record_execution_verification_batch(&db, &batch).await?; Defensive patterns
Strategy: validation
Validate before calling
// Rust: confirm an active intent exists before recording the action
let active = sqlx::query_scalar::<_, i64>(
"SELECT 1 FROM execution_intent WHERE intent_id = $1 AND chain_id = $2 AND wallet_address = $3 AND status = 'active'")
.bind(&batch.intent_id).bind(chain_id).bind(batch.wallet_address)
.fetch_optional(&db).await?;
if active.is_none() { return Err(anyhow::anyhow!("skip: intent {} not active", batch.intent_id)); } Type guard
fn normalize_wallet(addr: &str) -> String { addr.to_lowercase() } Prevention
- Track intent lifecycle locally; do not submit actions for completed/canceled intents.
- Normalize wallet address casing at creation and lookup.
- Include chain_id and wallet in intent IDs you log so mismatches are obvious.
When it happens
Trigger: Calling record_execution_verification_batch with an intent_id that is not present as an active intent for the given chain_id and wallet_address.
Common situations: Retrying after the intent already completed (double submission); referencing an intent from a different chain or wallet than it was created with; intent_id typo or ID from another environment's database; intent canceled/expired before the action was recorded.
Understand the failure class
Background: "Not found" and "does not exist" errors: why "Task not found", "No such folder", and "Can't find" fire when a lookup comes back empty — this error's family across 14 libraries.
Related errors
- Active execution intent {intent_id} was not found
- Implement FromRow for FuturesSpread
- Implement FromRow for OptionSpread
- Execution schema version {} is newer than supported version
- Verified finalized transaction count advanced without an act
AI-assisted analysis of nautechsystems/nautilus_trader@18893faf8b (2026-09-08).
Data as JSON: /api/errors/7e935c16c96357c6.
Report an issue: GitHub.