Repository navigation
Conversation
There was a problem hiding this comment.
go2 replay realtime (arm64)
Details
| Benchmark suite | Current: beb61d3 | Previous: f9c5a5c | Ratio |
|---|---|---|---|
peak memory |
1711.832 MB |
1795.23 MB |
0.95 |
peak threads |
356 threads |
366 threads |
0.97 |
network (transport) |
2731.011 MB |
2730.945 MB |
1.00 |
disk write |
1.754 MB |
1.723 MB |
1.02 |
instructions |
133.594 G |
137.801 G |
0.97 |
This comment was automatically generated by workflow using github-action-benchmark.
❌ 1 Tests Failed:
View the top 1 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
0982249 to
c9f7428
Compare
[Medium impact] The changes affect the shared path used to read MCAP recordings. Do not merge until mixed recordings retain typed legacy telemetry and control events; the current reader breaks consumers that access their event fields. Findings
SummaryThis PR adds automatic decoding for native MCAP recordings and routes the CLI through the generic reader.
Reviews (2) · Last reviewed commit: "fix: compare MCAP schemas by content and..." · Reviewed by Greptile |
| signature = (ch.message_encoding, ch.schema_id, tuple(sorted(ch.metadata.items()))) | ||
| if ch.topic in signatures and signatures[ch.topic] != signature: | ||
| raise ValueError(f"MCAP topic {ch.topic!r} has conflicting channel definitions") |
There was a problem hiding this comment.
Compatible channels block recordings
If two channels for the same topic reference identical schemas registered under different IDs, McapStore treats the IDs as a conflict and refuses to open the recording. The earlier reader opened such a recording and returned both messages. Compare the referenced schemas rather than their IDs; this regression must be fixed before merging.
Artifacts
- The authored script builds the MCAP and exercises the pre-change and working-tree store constructors, making the comparison reproducible.
- Running the reproduction against `684ee07428^` opened the file and returned both payloads, showing the baseline behavior.
- Running the same reproduction against the working tree raised the conflicting-channel `ValueError`, showing the regression.
| with path.open("wb") as output: | ||
| writer = Writer(output) | ||
| writer.start(profile="dimos") | ||
| channel = writer.register_channel( |
There was a problem hiding this comment.
Rust recordings lack reader coverage
The new automatic-decoding test writes its recording with Python’s Writer, while the Rust-recording tests give McapStore an explicit codec. The tests can therefore miss a mismatch between a Rust-written file and automatic decoding. A Python-written recording with Rust-shaped metadata decoded successfully, but that does not test an actual Rust-written file. Add a test that opens one without supplying a codec.
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Artifacts
- This script generated a Python-written fixture matching the Rust recorder’s declared channel shape and exercised both reader versions; it does not generate a recording with Rust.
- The command ran the pre-PR reader against the Rust-shaped fixture and observed a bytes stream, establishing the comparison baseline.
- The command ran the PR reader against the same Rust-shaped fixture without a codec and observed a typed Imu, showing the expected reader behavior.
- The command searched the relevant tests and located the Python Writer fixture and the explicit codec in the Rust-recorder test, confirming the uncovered combination.
- The attempted offline Cargo test exited 101 because `lcm-msgs` could not be checked out, preventing validation with an actual Rust-generated file.
Removed deprecated information about Rust MCAP inspection and generic replay.
c9f7428 to
c2f18c5
Compare
|
close as we'll just do cdr migration... |
| reader.get_header().profile != "dimos" | ||
| and channel.message_encoding == "json" | ||
| and channel.topic in {"telemetry", "control_log"} | ||
| and "dimos.payload_type" not in channel.metadata |
There was a problem hiding this comment.
Mixed recordings lose typed events
In a mixed recording with profile dimos, this condition skips the Go2 decoders for legacy JSON channels named telemetry or control_log when they lack dimos.payload_type. The generic reader then returns bytes instead of Telemetry or ControlEvent. Opening the same recording with the previous reader preserves those types; with this change, consumers accessing fields such as .battery or .lx raise AttributeError. Select these decoders from each channel’s encoding and metadata rather than the file-wide profile.
Artifacts
Exact executed mixed-recording verification script
- The authored harness creates both fixtures, executes base and head readers, and captures structured results with assertions, making the regression reproducible.
Reader output before the PR change
- Executed the supplied base reader through both opening APIs against both profiles, showing that legacy telemetry and control events retain their types.
Reader output after the PR change
- Executed head through both opening APIs against identical fixtures, showing raw bytes and failed typed field access only for dimos-profile legacy events.
Full-range relevant source diff and unchanged tracked-source check
- Captured the supplied base-to-head diff, numbered source excerpts, and successful tracked-source integrity check, tying the observed regression to the profile guard.
Interpreter setup and verification execution record
- Captured interpreter setup, Python version, successful before/after runs, tracked-source checks, and fixture hashes, documenting the actual execution.
Legacy-profile mixed-recording control fixture
- Generated and read a ros2-profile MCAP with native and legacy channels, demonstrating that the same legacy JSON remains typed under the control profile.
DimOS-profile mixed recording that reproduces the regression
- Generated and read a dimos-profile MCAP with native and legacy channels, demonstrating that head loses legacy decoded types while preserving their raw payloads.
Problem
Solution
dimos.payload_typemetadata. Keep unknown types as raw bytes.mcapto core dependencies. Reject conflicting channel definitions for the same topic.