{"record":{"id":"2c2cb8dcd13437f1","repo":"nautechsystems/nautilus_trader","slug":"debug-tracetransaction-request-failed","errorCode":null,"errorMessage":"debug_traceTransaction request failed","messagePattern":"debug_traceTransaction request failed","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/adapters/blockchain/src/rpc/http.rs","lineNumber":827,"sourceCode":"                {\n                    \"tracer\": \"callTracer\",\n                    \"tracerConfig\": {\n                        \"onlyTopCall\": false,\n                        \"withLog\": false,\n                    },\n                }\n            ],\n        });\n        let bytes = self\n            .send_rpc_request(request, Some(EXECUTION_RPC_TIMEOUT_SECS))\n            .await\n            .map_err(|e| match e {\n                BlockchainRpcClientError::ClientError(message)\n                    if message.contains(\"redirect response rejected\") =>\n                {\n                    anyhow::anyhow!(\"debug_traceTransaction redirect rejected\")\n                }\n                _ => anyhow::anyhow!(\"debug_traceTransaction request failed\"),\n            })?;\n        let parsed =\n            serde_json::from_slice::<RpcNodeHttpResponse<serde_json::Value>>(bytes.as_ref())\n                .map_err(|_| anyhow::anyhow!(\"Failed to parse debug_traceTransaction response\"))?;\n        if parsed.jsonrpc.is_none()\n            && let (Some(code), Some(_)) = (parsed.code, parsed.message)\n        {\n            return trace_probe_result(code);\n        }\n\n        if let Some(error) = parsed.error {\n            return trace_probe_result(error.code);\n        }\n        anyhow::ensure!(\n            parsed.result.is_some(),\n            \"debug_traceTransaction returned no result\"\n        );\n        Ok(())","sourceCodeStart":809,"sourceCodeEnd":845,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/18893faf8b356be3320add8de2f861b0b647cf06/crates/adapters/blockchain/src/rpc/http.rs#L809-L845","documentation":"`probe_call_trace` maps any transport error from its test `debug_traceTransaction` request that is not a rejected redirect to this generic \"request failed\" error, re-wrapping the underlying `BlockchainRpcClientError`. It signals the probe could not complete a successful HTTP exchange, so the endpoint's callTracer support could not be verified.","triggerScenarios":"Any non-redirect transport failure during the probe: connection refused/timeout, DNS failure, TLS errors, HTTP 5xx from the node, or the client error message not containing \"redirect response rejected\".","commonSituations":"Node down or unreachable (firewall, wrong host/port); `debug_*` namespace disabled causing error responses; timeouts on slow nodes; TLS certificate problems.","solutions":["Check node reachability: curl the endpoint with a trivial eth_chainId request","Confirm the `debug` API namespace is enabled (e.g. geth `--http.api ...,debug` or erigon trace namespace)","Look at the wrapped source error for the precise cause (timeout vs refused vs HTTP status)","Retry or move the probe/tracing to a dedicated trace-enabled node"],"exampleFix":"// before: debug namespace disabled -> probe request fails\n// geth flags: --http.api eth,net\n// after: enable debug/trace namespace\n// geth flags: --http.api eth,net,debug\n// erigon flags: --http.api eth,erigon,trace","handlingStrategy":"try-catch","validationCode":"async fn debug_api_available(url: &str) -> bool {\n    // any successful debug_* round trip proves the namespace is enabled\n    send_raw(url, json!({\"jsonrpc\":\"2.0\",\"method\":\"debug_traceTransaction\",\"params\":[known_tx_hash, {\"tracer\":\"callTracer\"}],\"id\":1}))\n        .await.is_ok()\n}","typeGuard":null,"tryCatchPattern":"match client.probe_call_trace().await {\n    Ok(()) => Ok(()),\n    Err(e) if e.to_string().contains(\"request failed\") => {\n        log::warn!(\"callTracer probe failed; check node reachability and debug namespace: {e}\");\n        Err(anyhow!(\"tracing endpoint unusable: {e}\"))\n    }\n    Err(e) => Err(e),\n}","preventionTips":["Enable the debug/trace namespace in node flags (--http.api eth,net,debug)","Verify reachability, DNS, and TLS with a simple eth_chainId curl before probing","Use dedicated trace-enabled nodes for debug_* workloads; don't probe disabled providers","Capture and log the wrapped source error to distinguish timeouts, refusals, and HTTP 5xx"],"tags":["rpc","tracing","debug-api","network"],"backgroundTag":"http-request-failed","analyzedSha":"18893faf8b356be3320add8de2f861b0b647cf06","analyzedAt":"2026-09-08T20:49:34.690Z","contentChangedAt":"2026-09-08T20:49:34.690Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}