AprilNEA/OpenLogi · error
the running Agent timed out while providing its device…
Error message
the running Agent timed out while providing its device snapshot
What it means
After client declaration, `capture_connected_profile` fetches the agent's device snapshot with a `SNAPSHOT_TIMEOUT`. The outer `Err` of `tokio::time::timeout` — no response in time — raises this error, indicating the agent accepted the request but could not deliver its snapshot promptly.
Solutions
- Retry the command; transient slowness often resolves
- Reduce concurrent agent load (close other CLI hardware sessions) and retry
- Restart the agent if it remains unresponsive
- If it recurs, profile the agent's snapshot/enumeration path for blocking I/O
Defensive patterns
Strategy: retry
Validate before calling
// ensure a fresh snapshot is cheap before capture
match tokio::time::timeout(Duration::from_secs(3), connect_and_snapshot_probe()).await {
Ok(Ok(_)) => println!("snapshot path healthy"),
_ => eprintln!("agent snapshot slow or broken; restart the agent"),
} Try / catch
for attempt in 0..2 {
match capture_connected_profile(&conn, ...).await {
Err(e) if e.to_string().contains("timed out while providing its device snapshot") && attempt == 0 => continue,
other => break other,
}
} Prevention
- Reduce concurrent agent load (DPI operations, other CLI sessions) during capture
- Retry after system resume settles
- Report/profile persistent slowness in the agent's enumeration path
When it happens
Trigger: `connection.client.snapshot(...)` does not complete within `SNAPSHOT_TIMEOUT` — the agent is busy enumerating HID devices, blocked on slow hardware, or its event loop is stalled after successful `declare_client`.
Common situations: Large inventory with slow/unresponsive devices, receiver rescans taking too long, agent doing a firmware/DPI operation concurrently, system under heavy load or just resumed from sleep.
Understand the failure class
Background: Request timed out: what client-side request timeouts mean across libraries (Request timed out, TIMED_OUT, APITimeoutError) — this error's family across 39 libraries.
- Timeouts: ETIMEDOUT, deadlines, and hung requests — what actually expires when a request times out.
Related errors
- the running Agent timed out before semantic capture could…
- the running Agent disconnected while providing its device…
- timed out connecting to the running OpenLogi Agent…
- the running Agent speaks protocol v
- could not reach the running OpenLogi Agent; start the Agent…
AI-assisted analysis of AprilNEA/OpenLogi@e846e6f4b4 (2026-09-13).
Data as JSON: /api/errors/95900addc5ad1b11.
Report an issue: GitHub.
Appendix: source
Thrown at crates/openlogi-cli/src/cmd/fixture/record_profile.rs:150
);
}
tokio::time::timeout(
DECLARE_TIMEOUT,
connection
.client
.declare_client(context::current(), ClientKind::Cli),
)
.await
.map_err(|_| anyhow!("the running Agent timed out before semantic capture could begin"))?
.map_err(|_| anyhow!("the running Agent disconnected before semantic capture could begin"))?;
let snapshot = tokio::time::timeout(
SNAPSHOT_TIMEOUT,
connection.client.snapshot(context::current()),
)
.await
.map_err(|_| anyhow!("the running Agent timed out while providing its device snapshot"))?
.map_err(|_| anyhow!("the running Agent disconnected while providing its device snapshot"))?;
let captured = capture_profile(&connection.client, snapshot, selector, id, name).await?;
captured
.profile
.validate()
.context("captured semantic profile failed version-1 validation; no profile was written")?;
Ok(captured)
}
fn validate_metadata(args: &RecordProfileArgs) -> Result<()> {
if args.id.trim().is_empty() {
bail!("--id must be a nonempty synthetic identifier");
}
if args.name.trim().is_empty() {
bail!("--name must be a nonempty synthetic profile name");
}
Ok(())View on GitHub (pinned to e846e6f4b4)