{"record":{"id":"cc04748224bedae2","repo":"nautechsystems/nautilus_trader","slug":"deployment-manifest-pool-does-not-use-the-pinned-p","errorCode":null,"errorMessage":"Deployment manifest pool does not use the pinned pool, factory, and quote identities","messagePattern":"Deployment manifest pool does not use the pinned pool, factory, and quote identities","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/adapters/blockchain/src/execution/client.rs","lineNumber":472,"sourceCode":"        for limit in config.quote_spend_limits.as_deref().unwrap_or_default() {\n            let spend_token = validate_address(&limit.spend_token)?;\n            anyhow::ensure!(\n                token_decimals.get(&spend_token) == Some(&limit.spend_token_decimals),\n                \"Quote spend limit decimals do not match the deployment manifest\"\n            );\n        }\n\n        let pool_contracts = role_addresses(BlockchainContractRole::Pool)?;\n\n        for pool in &manifest.pools {\n            let pool_address = Address::from_str(&pool.address)\n                .map_err(|_| anyhow::anyhow!(\"Deployment manifest pool address is invalid\"))?;\n            let pool_factory = Address::from_str(&pool.factory)\n                .map_err(|_| anyhow::anyhow!(\"Deployment manifest pool factory is invalid\"))?;\n            let pool_quote = Address::from_str(&pool.quote_contract).map_err(|_| {\n                anyhow::anyhow!(\"Deployment manifest pool quote contract is invalid\")\n            })?;\n            anyhow::ensure!(\n                pool_contracts.contains(&pool_address)\n                    && pool_factory == factory\n                    && pool_quote == quote_contract,\n                \"Deployment manifest pool does not use the pinned pool, factory, and quote identities\"\n            );\n        }\n        Ok(())\n    }\n\n    async fn fetch_native_currency_balance(&self) -> anyhow::Result<Money> {\n        let balance_u256 = self\n            .http_rpc_client\n            .get_balance_with_timeout(&self.wallet_address, None, Some(EXECUTION_RPC_TIMEOUT_SECS))\n            .await?;\n\n        let native_currency = self.chain.native_currency();\n\n        Money::from_u256(balance_u256, native_currency).map_err(Into::into)","sourceCodeStart":454,"sourceCodeEnd":490,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/18893faf8b356be3320add8de2f861b0b647cf06/crates/adapters/blockchain/src/execution/client.rs#L454-L490","documentation":"Beyond parseability, each manifest pool must match the pinned identities: the pool address must be registered under BlockchainContractRole::Pool, the factory must equal the deployment's pinned factory, and the quote contract must equal the pinned quote contract. Any mismatch fails validation, keeping manifest contents consistent with the configured contract roles.","triggerScenarios":"Calling preflight/validate_manifest_contracts where a manifest pool's address is not in the Pool-role address list, or pool.factory != factory, or pool.quote_contract != quote_contract.","commonSituations":"Manifest generated for a previous deployment whose factory/quote contracts were upgraded; pool registered under a different role; stale manifest committed after rotating contracts.","solutions":["Regenerate the deployment manifest from the current pinned contract set","Update config contract roles (Pool/factory/quote) to the deployment the manifest describes","Remove the stale pool entry from the manifest"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"for pool in &manifest.pools {\n    assert!(pool_contracts.contains(&Address::from_str(&pool.address)?), \"pool not registered under Pool role\");\n    assert_eq!(Address::from_str(&pool.factory)?, factory, \"factory mismatch\");\n    assert_eq!(Address::from_str(&pool.quote_contract)?, quote_contract, \"quote mismatch\");\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Regenerate the manifest whenever factory/quote contracts change","Version the manifest with the deployment it describes","Diff manifests against pinned contract roles in CI"],"tags":["validation","manifest","consistency"],"backgroundTag":"schema-validation-failed","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"}