nautechsystems/nautilus_trader · error · anyhow::Error
No durable store configured; refusing to load execution tran
Error message
No durable store configured; refusing to load execution transaction
What it means
get_execution_transaction reads an execution transaction row by chain id and hash, but requires a configured durable database. When the cache has no database, it returns this error rather than returning None, since a missing store is a configuration problem, not an absent record.
Source
Thrown at crates/adapters/blockchain/src/cache/mod.rs:243
database
.update_execution_transaction_status(chain_id, transaction_hash, status)
.await
}
/// Loads an execution transaction record by chain ID and transaction hash, failing closed
/// when no database is attached.
///
/// # Errors
///
/// Returns an error if no database is configured or the database operation fails.
pub async fn get_execution_transaction(
&self,
chain_id: u32,
transaction_hash: &str,
) -> anyhow::Result<Option<ExecutionTransactionRow>> {
let database = self.database.as_ref().ok_or_else(|| {
anyhow::anyhow!("No durable store configured; refusing to load execution transaction")
})?;
database
.get_execution_transaction(chain_id, transaction_hash)
.await
}
/// Toggles performance optimization settings in the database.
///
/// # Errors
///
/// Returns an error if the database is not initialized or the operation fails.
pub async fn toggle_performance_settings(&self, enable: bool) -> anyhow::Result<()> {
if let Some(database) = &self.database {
database.toggle_perf_sync_settings(enable).await
} else {
log::warn!("Database not initialized, skipping performance settings toggle");
Ok(())View on GitHub (pinned to 18893faf8b)
Solutions
- Configure the database on the cache before querying transactions
- Check self.database presence (or an equivalent accessor) before calling and handle the no-store case explicitly
- Fix the deployment/config so the database URL is provided
- If no store is expected, change the caller to skip the lookup instead of hitting the cache
Example fix
// before
let row = cache.get_execution_transaction(chain_id, &tx_hash).await?; // panics into error if no DB
// after
let row = match cache.database() {
Some(_) => cache.get_execution_transaction(chain_id, &tx_hash).await?,
None => None,
}; Defensive patterns
Strategy: validation
Validate before calling
if cache.database.is_none() {
eprintln!("cannot load execution transaction: no durable store configured");
} Type guard
fn can_query(cache: &BlockchainCache) -> bool {
cache.database.is_some()
} Try / catch
match cache.get_execution_transaction(chain_id, &tx_hash).await {
Err(e) if e.to_string().contains("No durable store configured") => {
// treat as config error, not record-not-found
}
other => other?,
} Prevention
- Distinguish 'no store' from 'no record' at call sites
- Provide the database URL in every environment that reads transactions
- Construct caches with a database wherever history lookups occur
- Test lookup paths with a configured store in CI
When it happens
Trigger: Calling get_execution_transaction(chain_id, tx_hash) on a BlockchainCache constructed without a database handle.
Common situations: Querying transaction history on a memory-only cache; deployments missing the database configuration; code paths shared between database-backed and non-database setups where the caller assumes a store exists.
Understand the failure class
Background: "X is required", "must be set", "cannot be empty": the missing-required-config error family, from Vertex AI project/location to WeChat keys — this error's family across 18 libraries.
Related errors
- No durable store configured; refusing to update execution tr
- Could not calculate schema dir from current directory path o
- Failed to set work_mem: {e}
- Legacy execution transaction {} contains an envelope
- Signed transaction envelope does not use the database active
AI-assisted analysis of nautechsystems/nautilus_trader@18893faf8b (2026-09-08).
Data as JSON: /api/errors/bbb95a1e49b9c525.
Report an issue: GitHub.