clankers-data 0.1.6

MCAP logging, replay, and inspection for clankeRS
Documentation

Read, write, replay, and compare MCAP robot logs — the backbone of clankeRS replay testing and offline debugging.

Install

clankers-data = "0.1"
cargo add clankers-data

Example

use clankers_data::{format_inspect_report, McapLog, Replay};

// Summarize topics and message counts
let log = McapLog::open("logs/run.mcap")?;
println!("{}", format_inspect_report(log.report()));

// Replay every message through your handler
let replay = Replay::from_mcap("logs/run.mcap")?;
let result = replay
    .run(|msg| async move {
        println!("{}: {} bytes", msg.topic, msg.data.len());
        Ok(())
    })
    .await?;
println!("replayed {} messages", result.summary.input_messages);

Key types

Type Role
Replay Async replay over an MCAP file
McapWriter Write timestamped messages to MCAP
McapLog, InspectReport Open a log and print a human summary
compare_logs Diff two MCAP files for regression checks

Learn more

License

MIT — see LICENSE.