FuelLabs/fuel-core · error · anyhow::Error

Tendermint RPC response ID {} does not match request ID {}

Error message

Tendermint RPC response ID {} does not match request ID {}

What it means

Response-correlation guard in rpc(): the JSON-RPC response's id field does not match the id sent in the request (hardcoded 1 on the client side). The server (or an intermediary) answered a different request than the one this call issued — possible with connection mix-ups, proxies, or non-conformant servers. The result payload must not be trusted because it belongs to another call.

Source

Thrown at crates/services/shared-sequencer/src/http_api.rs:145

    let response = http.post(api_url).json(&request).send().await?;
    if response.status() != reqwest::StatusCode::OK {
        anyhow::bail!(
            "Tendermint RPC request failed with HTTP status {}",
            response.status()
        );
    }
    let text = response.text().await?;
    let response: api_types::RpcResponse<T> =
        serde_json::from_str(&text).with_context(|| format!("response text {text}"))?;

    if response.jsonrpc != request.jsonrpc {
        anyhow::bail!(
            "Tendermint RPC response uses unsupported JSON-RPC version {}",
            response.jsonrpc
        );
    }
    if response.id != request.id {
        anyhow::bail!(
            "Tendermint RPC response ID {} does not match request ID {}",
            response.id,
            request.id
        );
    }

    if let Some(error) = response.error {
        anyhow::bail!("Tendermint RPC error: {error}");
    }

    response
        .result
        .ok_or_else(|| anyhow::anyhow!("Tendermint RPC response has no result"))
}

#[derive(Copy, Clone, Debug, Default)]
pub struct AccountMetadata {
    pub account_number: u64,

View on GitHub (pinned to add100d30d)

Solutions

  1. Reject the response and re-issue the request — never consume the mismatched result
  2. Use unique incrementing request IDs per client instead of a constant to make cross-talk detectable
  3. Check for intermediaries (load balancers, caches) that could return stale or mismatched RPC responses
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at crates/services/shared-sequencer/src/http_api.rs:145 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of FuelLabs/fuel-core@add100d30d (2026-09-05). Data as JSON: /api/errors/1e29c4fa6850390c. Report an issue: GitHub.