{"record":{"id":"8ccdd24d756f602d","repo":"FuelLabs/fuel-core","slug":"invalid-order","errorCode":null,"errorMessage":"Invalid order","messagePattern":"Invalid order","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/services/shared-sequencer/src/http_api.rs","lineNumber":311,"sourceCode":"    let path = format!(\"/fuelsequencer/sequencing/v1/topic/{id_b64}\");\n    let full_url = Url::parse(api_url)?.join(&path).unwrap();\n    let r = http.get(full_url).send().await?;\n    if r.status() == 404 {\n        return Ok(None);\n    }\n    let text = r.text().await?;\n    let resp: api_types::TopicResponse =\n        serde_json::from_str(&text).with_context(|| format!(\"response text {text}\"))?;\n    let owner = resp\n        .topic\n        .owner\n        .parse()\n        .map_err(|_| anyhow::anyhow!(\"Invalid owner\"))?;\n    let order = resp\n        .topic\n        .order\n        .parse()\n        .map_err(|_| anyhow::anyhow!(\"Invalid order\"))?;\n    Ok(Some(TopicInfo { owner, order }))\n}\n\n#[cfg(test)]\nmod tests {\n    use super::*;\n    use mockito::Matcher;\n    use serde_json::json;\n\n    #[tokio::test]\n    async fn latest_block_height_uses_tendermint_json_rpc_shape() {\n        let mut server = mockito::Server::new_async().await;\n        let mock = server\n            .mock(\"POST\", \"/\")\n            .match_body(Matcher::Json(json!({\n                \"jsonrpc\": \"2.0\",\n                \"id\": 1,\n                \"method\": \"abci_info\",","sourceCodeStart":293,"sourceCodeEnd":329,"githubUrl":"https://github.com/FuelLabs/fuel-core/blob/add100d30d21498e8528c46be8567fbd2ea019af/crates/services/shared-sequencer/src/http_api.rs#L293-L329","documentation":"Parse guard in get_topic(): the topic's \"order\" field, fetched from the sequencer's /topic/{id_b64} REST endpoint, failed to parse into the expected numeric/typed order value. The API returned 200 and the JSON deserialized into TopicResponse, but the order string is not in the representable format (e.g. non-numeric, empty, or out-of-range), so .parse() returned Err and it is mapped to this sentinel error.","triggerScenarios":"Thrown at crates/services/shared-sequencer/src/http_api.rs:311 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Log the raw resp.topic.order string to see the exact unparseable value","Check for API version mismatch between the shared-sequencer topic endpoint and this client's expected order format","If order can legitimately be absent/unknown, parse into an Option and default instead of failing the whole get_topic call","Validate topic registration data upstream so only well-formed order values are stored"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"add100d30d21498e8528c46be8567fbd2ea019af","analyzedAt":"2026-09-05T18:46:12.018Z","contentChangedAt":"2026-09-05T18:46:12.018Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}