{"record":{"id":"37a6062597a10630","repo":"nautechsystems/nautilus_trader","slug":"ax-dated-contract-has-different-quote-and-settl","errorCode":null,"errorMessage":"AX dated contract {} has different quote and settlement currencies: {} and {}","messagePattern":"AX dated contract (.+?) has different quote and settlement currencies: (.+?) and (.+?)","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/adapters/architect_ax/src/http/parse.rs","lineNumber":296,"sourceCode":"        );\n    }\n\n    if let Some(v) = definition.price_band_upper_deviation_pct {\n        info.insert(\n            \"price_band_upper_deviation_pct\".to_string(),\n            json!(v.to_string()),\n        );\n    }\n\n    if let Some(v) = definition.price_band_lower_deviation_pct {\n        info.insert(\n            \"price_band_lower_deviation_pct\".to_string(),\n            json!(v.to_string()),\n        );\n    }\n\n    if let Some(expiration) = definition.expiration {\n        anyhow::ensure!(\n            definition.quote_currency == definition.funding_settlement_currency,\n            \"AX dated contract {} has different quote and settlement currencies: {} and {}\",\n            definition.symbol,\n            definition.quote_currency,\n            definition.funding_settlement_currency\n        );\n        let expiration_ns = datetime_to_unix_nanos(Some(expiration))\n            .context(\"Failed to convert AX contract expiration to Unix nanoseconds\")?;\n        let multiplier = decimal_to_quantity(definition.multiplier, \"multiplier\")?;\n        info.insert(\n            \"expiration\".to_string(),\n            json!(expiration.display_with_offset(Offset::UTC).to_string()),\n        );\n        info.insert(\n            \"activation_source\".to_string(),\n            json!(\"unavailable_from_ax\"),\n        );\n","sourceCodeStart":278,"sourceCodeEnd":314,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/a4b06ed870971b5671d12754ea138a3ab99b1dec/crates/adapters/architect_ax/src/http/parse.rs#L278-L314","documentation":"For definitions with an expiration (dated futures), the parser requires quote_currency == funding_settlement_currency, because dated contracts are mapped onto a single-currency contract model (info gets one expiration and multiplier). A contract quoted in one currency but settled in another (inverse-style or cross-collateral futures) is rejected.","triggerScenarios":"A dated future quoted in USD but settled in USDC or the base asset (e.g. quote_currency=USD, funding_settlement_currency=BTC); any new dated contract with cross-collateral settlement hits this on instrument load.","commonSituations":"AX lists inverse or multi-collateral dated futures after the adapter was written; contract config with a typo'd settlement currency that differs from the quote; environments mirroring exotic exchange contracts.","solutions":["Verify both fields for the symbol (curl /instrument) and confirm the mismatch is real, not a config typo","If the currencies are operationally the same (e.g. USD vs USDC by convention), align funding_settlement_currency in venue config with the quote currency","For genuine cross-currency settlement, the adapter's contract model must be extended — file an issue with the symbol's raw definition; do not drop the check","Exclude the contract from subscription until supported"],"exampleFix":"// before (AX contract metadata)\n{\"symbol\": \"BTC-27MAR26\", \"quote_currency\": \"USD\", \"funding_settlement_currency\": \"BTC\"}\n// after\n{\"symbol\": \"BTC-27MAR26\", \"quote_currency\": \"USD\", \"funding_settlement_currency\": \"USD\"}","handlingStrategy":"try-catch","validationCode":"// Pre-check dated-contract currency alignment if you vet definitions upstream\nif definition.expiration.is_some()\n    && definition.quote_currency != definition.funding_settlement_currency\n{\n    anyhow::bail!(\n        \"dated contract {} settles in {} but quotes in {}; unsupported cross-currency settlement\",\n        definition.symbol, definition.funding_settlement_currency, definition.quote_currency\n    );\n}","typeGuard":null,"tryCatchPattern":"match parse_instrument(&definition, ts_event, ts_init) {\n    Ok(instrument) => Ok(instrument),\n    Err(e) if e.to_string().contains(\"different quote and settlement currencies\") => {\n        log::error!(\"cross-collateral dated contract {} unsupported by adapter\", definition.symbol);\n        Err(e)\n    }\n    Err(e) => Err(e),\n}","preventionTips":["Keep quote and settlement currencies identical in AX config for dated contracts","Screen new listings for cross-currency settlement before enabling subscription","File an adapter issue with the raw definition when a legitimate contract is rejected — extension is a code change"],"tags":["architect-ax","instrument","futures","currency","validation"],"backgroundTag":"invalid-instrument-metadata","analyzedSha":"a4b06ed870971b5671d12754ea138a3ab99b1dec","analyzedAt":"2026-08-16T22:54:50.089Z","schemaVersion":2},"datasetVersion":"2026-08-16T23:17:17.608Z"}