nautechsystems/nautilus_trader · error
Loading order snapshots from Redis cache adapter not support
Error message
Loading order snapshots from Redis cache adapter not supported
What it means
load_order_snapshot is an intentionally unimplemented method on the Redis cache adapter; it always bails with this message. Order snapshots cannot be read back from the Redis-backed cache, so any code path requesting one will fail immediately.
Source
Thrown at crates/infrastructure/src/redis/cache.rs:1598
fn load_strategy(&self, strategy_id: &StrategyId) -> anyhow::Result<AHashMap<String, Bytes>> {
let key = format!("{STRATEGIES}{REDIS_DELIMITER}{strategy_id}{REDIS_DELIMITER}state");
self.load_state(key)
}
fn load_signals(&self, _name: &str) -> anyhow::Result<Vec<Signal>> {
anyhow::bail!("Loading signals from Redis cache adapter not supported")
}
fn load_custom_data(&self, data_type: &DataType) -> anyhow::Result<Vec<CustomData>> {
self.database.load_custom_data(data_type)
}
fn load_order_snapshot(
&self,
_client_order_id: &ClientOrderId,
) -> anyhow::Result<Option<OrderSnapshot>> {
anyhow::bail!("Loading order snapshots from Redis cache adapter not supported")
}
fn load_position_snapshot(
&self,
_position_id: &PositionId,
) -> anyhow::Result<Option<PositionSnapshot>> {
anyhow::bail!("Loading position snapshots from Redis cache adapter not supported")
}
fn load_quotes(&self, _instrument_id: &InstrumentId) -> anyhow::Result<Vec<QuoteTick>> {
anyhow::bail!("Loading quote data for Redis cache adapter not supported")
}
fn load_trades(&self, _instrument_id: &InstrumentId) -> anyhow::Result<Vec<TradeTick>> {
anyhow::bail!("Loading market data for Redis cache adapter not supported")
}
fn load_funding_rates(View on GitHub (pinned to 18893faf8b)
Solutions
- Reconstruct order state via load_order / index-based loads instead of load_order_snapshot.
- Use a backing adapter that implements snapshot loading if snapshots are required.
- Handle the error explicitly, returning None semantics in calling code when the adapter cannot provide snapshots.
- Feature-gate snapshot restore so it only runs with a capable cache backend.
Example fix
// before let snapshot = cache.load_order_snapshot(&client_order_id)?; // bails on Redis // after let snapshot = cache.load_order_snapshot(&client_order_id).ok().flatten(); // graceful degrade
Defensive patterns
Strategy: fallback
Validate before calling
// Python
if isinstance(cache_database, RedisCacheDatabase):
snapshot = None # unsupported on Redis
else:
snapshot = cache.load_order_snapshot(client_order_id) Try / catch
// Python
try:
snapshot = cache.load_order_snapshot(client_order_id)
except RuntimeError as e:
if "order snapshot" in str(e) and "not supported" in str(e):
snapshot = None
else:
raise Prevention
- Rebuild order state from load_order/indexes rather than snapshots on Redis.
- Check adapter docs for supported load_* methods before designing recovery flows.
- Wrap snapshot loads so None is the fallback, never a crash.
When it happens
Trigger: Calling cache.load_order_snapshot(client_order_id) (or flows that reconstruct order snapshots from cache) while using the Redis cache adapter.
Common situations: Reconciliation or recovery logic that expects snapshot restore from Redis; migration scripts reading historical orders as snapshots; adapting code written for adapters that do implement snapshot loading.
Related errors
- Loading signals from Redis cache adapter not supported
- Loading position snapshots from Redis cache adapter not supp
- Loading quote data for Redis cache adapter not supported
- Failed to send to channel: {e}
- Unsupported operation: `insert` for collection '{collection}
AI-assisted analysis of nautechsystems/nautilus_trader@18893faf8b (2026-09-08).
Data as JSON: /api/errors/1da15d91e0a899e5.
Report an issue: GitHub.