{"record":{"id":"c300e02b143e45aa","repo":"nautechsystems/nautilus_trader","slug":"incompleteorderreports-reports-detail-detail-i","errorCode":null,"errorMessage":"IncompleteOrderReports { reports, detail: detail.into() }","messagePattern":"IncompleteOrderReports (.+?)","errorType":"exception","errorClass":"IncompleteOrderReports","httpStatus":null,"severity":"error","filePath":"crates/adapters/lighter/src/execution.rs","lineNumber":4845,"sourceCode":"// account, so a market-scoped sweep can serve nothing while older trades for that\n// market have already been evicted by newer trades in other markets.\nstruct FillSweep {\n    reports: Vec<FillReport>,\n    covers_window: bool,\n}\n\n#[derive(Debug, thiserror::Error)]\n#[error(\"incomplete Lighter order reports: {detail}\")]\nstruct IncompleteOrderReports {\n    reports: Vec<OrderStatusReport>,\n    detail: String,\n}\n\nfn incomplete_order_reports(\n    reports: Vec<OrderStatusReport>,\n    detail: impl Into<String>,\n) -> anyhow::Error {\n    anyhow::Error::new(IncompleteOrderReports {\n        reports,\n        detail: detail.into(),\n    })\n}\n\nfn partial_order_reports(error: &anyhow::Error) -> Vec<OrderStatusReport> {\n    error\n        .downcast_ref::<IncompleteOrderReports>()\n        .map(|incomplete| incomplete.reports.clone())\n        .unwrap_or_default()\n}\n\nfn is_commission_error(error: &anyhow::Error) -> bool {\n    error\n        .chain()\n        .any(|cause| cause.downcast_ref::<LighterCommissionError>().is_some())\n}\n","sourceCodeStart":4827,"sourceCodeEnd":4863,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/d1527c24afdf475115785557f89a55c3e336c51f/crates/adapters/lighter/src/execution.rs#L4827-L4863","documentation":"The Lighter execution adapter received an incomplete set of order status reports (e.g. during mass status or reconciliation) and bails out with a typed IncompleteOrderReports error that carries the partial reports and a detail string. The helper shown constructs this error.","triggerScenarios":"Calling a Lighter mass-order-status or reconciliation flow where the venue returns fewer/malformed order reports than expected for the requested order IDs.","commonSituations":"Venue API changes or pagination quirks dropping reports, network interruption mid-poll, or requesting status for orders the venue no longer tracks.","solutions":["Read detail (the wrapped message) — it states which request was incomplete","Retry the mass status request; transient venue-side gaps often resolve","Use partial_order_reports(error) to recover the reports that did arrive and reconcile what you can","If persistent, check Lighter API announcements for endpoint changes"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":"fn is_incomplete_reports(e: &anyhow::Error) -> bool {\n    e.downcast_ref::<IncompleteOrderReports>().is_some()\n}","tryCatchPattern":"match run_mass_status().await {\n    Err(e) if is_incomplete_reports(&e) => {\n        let partial = partial_order_reports(&e);\n        reconcile_partial(partial).await?;\n    }\n    other => other?,\n}","preventionTips":["Handle IncompleteOrderReports as a typed case and reconcile partials","Retry mass status with backoff on transient gaps","Pin adapter version against known-good Lighter API behavior"],"tags":["lighter","execution","order-status","reconciliation"],"backgroundTag":"incomplete-order-reports","analyzedSha":"d1527c24afdf475115785557f89a55c3e336c51f","analyzedAt":"2026-08-27T04:01:12.327Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}