backplane-tracecheck 0.2.0__tar.gz → 0.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/.gitignore +5 -0
- backplane_tracecheck-0.4.0/CHANGELOG.md +100 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/PKG-INFO +35 -14
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/README.md +34 -13
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/docs/CONTRACT_REFERENCE.md +33 -5
- backplane_tracecheck-0.4.0/docs/COVERED_LIST_TRACKER.md +35 -0
- backplane_tracecheck-0.4.0/docs/FEEDBACK.md +83 -0
- backplane_tracecheck-0.4.0/examples/bad-index.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/expected.json +190 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag/fleet-bag_0.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag/fleet-bag_1.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag/fleet-bag_2.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag/metadata.yaml +60 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag-interrupted/fleet-bag-interrupted_0.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag-interrupted/fleet-bag-interrupted_1.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/fleet-bag-interrupted/fleet-bag-interrupted_2.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/fleet-paused-zstd.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/indexless-rosbag2.mcap +0 -0
- backplane_tracecheck-0.4.0/examples/interrupted-zstd.mcap +0 -0
- backplane_tracecheck-0.4.0/src/tracecheck/__init__.py +1 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/src/tracecheck/__main__.py +83 -7
- backplane_tracecheck-0.4.0/src/tracecheck/bag.py +322 -0
- backplane_tracecheck-0.4.0/src/tracecheck/engine.py +734 -0
- backplane_tracecheck-0.4.0/src/tracecheck/events.py +186 -0
- backplane_tracecheck-0.4.0/src/tracecheck/manifest.py +195 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/src/tracecheck/reader.py +307 -31
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/src/tracecheck/report.py +11 -2
- backplane_tracecheck-0.4.0/src/tracecheck/samples.py +284 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/src/tracecheck/ui.html +1 -1
- backplane_tracecheck-0.4.0/tests/test_bag.py +192 -0
- backplane_tracecheck-0.4.0/tests/test_events.py +212 -0
- backplane_tracecheck-0.4.0/tests/test_index.py +101 -0
- backplane_tracecheck-0.4.0/tests/test_manifest.py +144 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/tests/test_streaming.py +3 -2
- backplane_tracecheck-0.4.0/tests/test_truncated.py +99 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/app.css +63 -5
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/app.js +192 -23
- backplane_tracecheck-0.4.0/web/src/engine/bag.js +326 -0
- backplane_tracecheck-0.4.0/web/src/engine/engine.js +589 -0
- backplane_tracecheck-0.4.0/web/src/engine/events.js +158 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/reader.js +274 -26
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/report.js +13 -2
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/worker.js +11 -6
- backplane_tracecheck-0.4.0/web/src/feedback-schema.js +34 -0
- backplane_tracecheck-0.4.0/web/src/feedback.js +164 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/landing.css +57 -39
- backplane_tracecheck-0.4.0/web/src/main.js +6 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/style.css +2 -1
- backplane_tracecheck-0.4.0/web/src/tracker-data.js +97 -0
- backplane_tracecheck-0.4.0/web/src/tracker.css +109 -0
- backplane_tracecheck-0.4.0/web/src/tracker.js +148 -0
- backplane_tracecheck-0.2.0/CHANGELOG.md +0 -47
- backplane_tracecheck-0.2.0/src/tracecheck/__init__.py +0 -1
- backplane_tracecheck-0.2.0/src/tracecheck/engine.py +0 -310
- backplane_tracecheck-0.2.0/src/tracecheck/samples.py +0 -103
- backplane_tracecheck-0.2.0/web/src/engine/engine.js +0 -232
- backplane_tracecheck-0.2.0/web/src/main.js +0 -42
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/LICENSE +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/NOTICE +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/docs/THIRD_PARTY_NOTICES.md +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/docs/licenses/lz4-LICENSE.txt +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/docs/licenses/zstandard-LICENSE.txt +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/clean-lz4.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/clean-zstd.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/clean.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/demo-contract.json +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/faults.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/fleet-contract.json +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/fleet-dropout-lz4.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/fleet-zstd.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/malformed.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/no-crc.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/truncated.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/unchunked.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/examples/unsupported-codec.mcap +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/pyproject.toml +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/src/tracecheck/contract.py +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/src/tracecheck/server.py +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/tests/test_checker.py +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/chrome.js +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/contract.js +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/crc32.js +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/json.js +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/lz4.js +0 -0
- {backplane_tracecheck-0.2.0 → backplane_tracecheck-0.4.0}/web/src/engine/vendor/fzstd.js +0 -0
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# Local-only material (old reports, governance files, MVP evidence). Never committed.
|
|
2
2
|
archive/
|
|
3
|
+
Backplane Robotics Developer Directions.md
|
|
4
|
+
*.local.md
|
|
5
|
+
# Source documents (FCC Public Notices and similar) are kept locally for checking, never committed.
|
|
6
|
+
# The site links to the official copies online.
|
|
7
|
+
*.pdf
|
|
3
8
|
|
|
4
9
|
# Python
|
|
5
10
|
.venv/
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project are documented here. The format follows
|
|
4
|
+
[Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and the project uses
|
|
5
|
+
[Semantic Versioning](https://semver.org/).
|
|
6
|
+
|
|
7
|
+
## [Unreleased]
|
|
8
|
+
|
|
9
|
+
## [0.4.0] - 2026-11-03
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
- **Summary index agreement (C01, full scan).** Many tools jump through an MCAP file's summary indexes instead of
|
|
13
|
+
reading every record. C01 now checks that each Chunk, Attachment and Metadata index entry points to a record of that
|
|
14
|
+
type and length (for chunks, also compression, sizes and time range), that an index covers every record of its type,
|
|
15
|
+
and that the Statistics record matches the counts and times actually read. A disagreement **warns** and lists each
|
|
16
|
+
wrong entry or statistic; the records themselves are read directly, so the other checks are unaffected. Prompted by
|
|
17
|
+
MCAP TypeScript 2.4.0, which fixed attachment and metadata index offsets that could be wrong while messages were
|
|
18
|
+
buffered. Files with no indexes and no Statistics get a *skipped* (no conclusion) finding.
|
|
19
|
+
- `bad-index.mcap` synthetic example (intact records, wrong attachment and metadata index entries) and
|
|
20
|
+
`indexless-rosbag2.mcap` (no indexes, embedded `rosbag2` metadata; ROS 2's own reader has been reported to mis-read
|
|
21
|
+
such files, rosbag2 issue #2530).
|
|
22
|
+
- CI also runs the Python tests with `mcap` 1.6.
|
|
23
|
+
- **C08 largest backwards jump.** When record-order timestamps go backwards, the finding also reports
|
|
24
|
+
`largest_regression_ns` and the message pair where the largest jump happened, so small reordering jitter can be told
|
|
25
|
+
apart from a likely clock reset. Pass/fail is unchanged.
|
|
26
|
+
- Web app: "Wrong summary index" demo recording.
|
|
27
|
+
|
|
28
|
+
### Changed
|
|
29
|
+
- **Fast mode** falls back to a full scan, with a `fast_mode_fallback` reason, when the summary's metadata index does
|
|
30
|
+
not point to a Metadata record. Previously the scan stopped and the file was reported as unreadable.
|
|
31
|
+
- Web app: the result view shows the new C01 index facts and C08's largest backwards jump.
|
|
32
|
+
|
|
33
|
+
### Fixed
|
|
34
|
+
- Website: one small web font was embedded in the build as a `data:` URL, which the site's own security policy
|
|
35
|
+
(`font-src 'self'`) blocked. Fonts are now always served as files.
|
|
36
|
+
|
|
37
|
+
### Website
|
|
38
|
+
- FCC Covered List robot tracker: added Vulcan (DA 26-1130), Haystack and T-Robotics (DA 26-1154) on 2026-10-28, and
|
|
39
|
+
ARAPL, ATI Motors, Lightberry, SunScout, Swap Robotics and OMRON (DA 26-1181) on 2026-11-03. All 13 entries are checked
|
|
40
|
+
against Appendix B of DA 26-1181, the FCC's full list of robotic-device conditional approvals.
|
|
41
|
+
- Tracker page: a note explaining that waivers (for example DA 26-1146 for Intel) are not Covered List exemptions and are
|
|
42
|
+
not listed.
|
|
43
|
+
|
|
44
|
+
## [0.3.0] - 2026-10-20
|
|
45
|
+
|
|
46
|
+
### Added
|
|
47
|
+
- **Incomplete recordings.** A file that ends before its MCAP footer (for example, a recorder that stopped mid-write, or a file cut off while copying) now gets a specific C01 finding and a `recovered` report section: readable bytes, complete messages, log-time span, per-topic counts, and whether all message data was read. The other checks stay skipped; they are not evaluated on partial data. Shown in the CLI summary, the web app and the HTML report.
|
|
48
|
+
- `interrupted-zstd.mcap` synthetic example and web demo.
|
|
49
|
+
- **Gaps explained by recorder events.** When a recording contains rosbag2_dynamic_recorder (dynrec) `PauseEvent` or `SubscriptionChangeEvent` messages, C07 lists gaps covered by a recorded pause or topic unsubscribe as *explained* (with `explained_gap_count` and `explained_gaps`); they don't fail. Unexplained gaps still fail. The events are the recorder's own account and are not verified. Only their action and topic name are read; all other payloads stay opaque. Applies to the `log_time` basis only. A new top-level `recorder_events` section summarises the events found.
|
|
50
|
+
- `fleet-paused-zstd.mcap` synthetic example and "Paused recording (dynrec)" web demo.
|
|
51
|
+
- FCC Covered List robot tracker page on the website (`/tools/covered-list-robots/`).
|
|
52
|
+
- **ROS 2 bag folders.** `tracecheck check <folder>` and the web app (*Choose a bag folder*, or drop a folder) check a rosbag2 folder (`metadata.yaml` plus split `.mcap` files) as one recording. Channels are matched across files, so gaps, regressions and sequence breaks across file boundaries count. New check **C11 ROS 2 bag metadata agreement** compares the folder and the per-file, per-topic and total message counts with `metadata.yaml`; a listed file that is missing fails, and an unlisted `.mcap` warns and is not checked. A new `bag` report section lists each file with its size, SHA-256 and scan state; finding locations include a `file` key; `recovered` names the `incomplete_file`. Non-MCAP storage and rosbag2 file compression are refused (exit 2).
|
|
53
|
+
- `fleet-bag/` and `fleet-bag-interrupted/` synthetic examples and web demos.
|
|
54
|
+
- **`tracecheck manifest` and `tracecheck verify`.** Write a JSON manifest of an `.mcap` file or a ROS 2 bag folder (each file's size and SHA-256, plus the message count per topic), then check a copy against it after transfer. Each file is reported as match, changed, missing or extra; exit 0 when everything matches, 1 when something differs. A matching hash identifies the same bytes; it does not establish who made the recording or that its contents are true, and the manifest is not signed.
|
|
55
|
+
|
|
56
|
+
### Changed
|
|
57
|
+
- Fast mode falls back to a full scan when the file doesn't end with the MCAP magic bytes, so incomplete files get the recovered summary.
|
|
58
|
+
- Web demo list: the interrupted fleet recording replaces the small truncated demo; the dropout demo is correctly described as a lidar (`/scan`) outage.
|
|
59
|
+
- Tracecheck page and landing page Pro note: "folder-based processing" now reads "checking many recordings at once", since checking one bag folder is free.
|
|
60
|
+
- **C06 average rate leaves out recorded pauses.** When a recording contains dynrec pause or unsubscribe events, the rate bounds are applied to `active_hz`, which leaves out the time those events cover. The finding also reports `observed_hz` (whole span, as before), `excluded_ns` and `excluded_by`. Recordings without such events are unchanged.
|
|
61
|
+
|
|
62
|
+
## [0.2.0] - 2026-10-14
|
|
63
|
+
|
|
64
|
+
### Added
|
|
65
|
+
- **Compressed chunks.** zstd and lz4 chunks are decoded, with output strictly capped at the declared uncompressed size, so decompression bombs fail safely.
|
|
66
|
+
- **Streaming reader** (`tracecheck.reader`): a self-contained, bounded MCAP parser. SHA-256 and CRCs are computed in a single pass, and memory is bounded by explicit limits. The 64 MiB file-size cap is gone.
|
|
67
|
+
- **Fast mode** (`--fast`): reads only the summary section for an instant inventory, counts, schemas and metadata check. It falls back to a full scan when the summary is missing or incomplete.
|
|
68
|
+
- **`missing_crc` contract key** (`"warn"` or `"ignore"`) and the `--ignore-missing-crc` flag.
|
|
69
|
+
- Summary-section CRC verification.
|
|
70
|
+
- CLI flags: `--fail-on`, `--timeout`, `--max-chunk-mib`, `--max-record-mib`, `--max-tracked-messages`, `--quiet`, `--version`, and `samples --dest`.
|
|
71
|
+
- Report fields (`report_version` 2): `scan_mode`, `fast_mode_fallback`, `compression`, `scan_stats`, `checksum_coverage`.
|
|
72
|
+
- More synthetic examples: zstd, lz4, unchunked, no-CRC, unsupported-codec, malformed and truncated files, plus a 4-topic mobile-robot recording with and without a sensor dropout. `examples/expected.json` holds the golden results shared by the Python and browser test suites.
|
|
73
|
+
- **Web app** (`web/`): a browser-only static site for backplanerobotics.com with the Tracecheck app.
|
|
74
|
+
- A JavaScript port of the engine running in a Web Worker. Files never leave the browser.
|
|
75
|
+
- Handles multi-GB files and zstd/lz4 chunks.
|
|
76
|
+
- Demo recordings, a contract editor, and JSON/HTML report downloads.
|
|
77
|
+
- Reports are byte-identical to the Python CLI's, apart from timestamps and tool fields.
|
|
78
|
+
- A strict Content-Security-Policy.
|
|
79
|
+
|
|
80
|
+
### Changed
|
|
81
|
+
- Renamed the project from "Recording Health Checker" to **Backplane Tracecheck**.
|
|
82
|
+
- The Python package `rhc` is now `tracecheck`.
|
|
83
|
+
- The PyPI distribution is `backplane-tracecheck`.
|
|
84
|
+
- The CLI command is `tracecheck`.
|
|
85
|
+
- `tracecheck check` runs in-process, with no subprocess and no size cap. The local `serve` UI keeps its 64 MiB upload limit.
|
|
86
|
+
- **Missing-CRC rule.** C01 now warns only when some message data has no CRC coverage. Default ROS 2 files, which have chunk CRCs but no data-section CRC, now pass.
|
|
87
|
+
- Packaged with `pyproject.toml` (hatchling), replacing `requirements*.txt` and the Windows `.cmd` launchers.
|
|
88
|
+
- Relicensed as Apache-2.0 open source.
|
|
89
|
+
|
|
90
|
+
### Fixed
|
|
91
|
+
- The local server no longer returns stderr text or the user's home path in error responses.
|
|
92
|
+
- The local server now requires a matching `Origin` header on POST requests.
|
|
93
|
+
|
|
94
|
+
### Removed
|
|
95
|
+
- MVP governance, evidence, QA and marketing files were moved out of the repository into a local archive.
|
|
96
|
+
|
|
97
|
+
## [0.1.0] - 2026-10-13
|
|
98
|
+
|
|
99
|
+
### Added
|
|
100
|
+
- Initial MVP: CLI and local browser UI, 10 contract checks, JSON and HTML reports, and synthetic examples.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: backplane-tracecheck
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.4.0
|
|
4
4
|
Summary: Check robot recordings (MCAP) against an explicit, versioned recording contract.
|
|
5
5
|
Project-URL: Homepage, https://backplanerobotics.com
|
|
6
6
|
Project-URL: Source, https://github.com/backplane-robotics/backplane-tracecheck
|
|
@@ -31,15 +31,17 @@ Description-Content-Type: text/markdown
|
|
|
31
31
|
|
|
32
32
|
# Backplane Tracecheck
|
|
33
33
|
|
|
34
|
-
**Check robot recordings against an explicit recording contract
|
|
34
|
+
**Vendor-neutral recording integrity checks.** Check robot recordings against an explicit recording contract.
|
|
35
35
|
|
|
36
|
-
Tracecheck reads an [MCAP](https://mcap.dev) recording (the default ROS 2 bag format) and checks it against a small JSON *recording contract*: which topics must be present, their schemas and encodings, message counts, rates, timestamp gaps, regressions, sequence continuity and time coverage. It produces a JSON report and a readable HTML report.
|
|
36
|
+
Tracecheck reads an [MCAP](https://mcap.dev) recording (the default ROS 2 bag format) and checks it against a small JSON *recording contract*: which topics must be present, their schemas and encodings, message counts, rates, timestamp gaps, regressions, sequence continuity and time coverage. It produces a JSON report and a readable HTML report. Findings include relevant file locations where available; missing items are reported as gaps.
|
|
37
37
|
|
|
38
38
|
- Free and open source (Apache-2.0).
|
|
39
|
-
- Read-only. Message payloads are never decoded
|
|
39
|
+
- Read-only. Message payloads are never executed, and are not decoded, with one narrow exception: from recognised recorder event messages (rosbag2_dynamic_recorder pause and topic events) only the action and topic name are read.
|
|
40
|
+
- Gaps covered by a pause or topic change that the recorder wrote into the recording are listed as explained instead of failing. The events are the recorder's own account; Tracecheck does not verify them.
|
|
41
|
+
- Checks a ROS 2 bag folder (`metadata.yaml` plus split `.mcap` files) as one recording: gaps and sequence breaks across file boundaries count, and the counts in `metadata.yaml` are compared with what the files contain (C11).
|
|
40
42
|
- No robot, ROS install, account or cloud service needed.
|
|
41
|
-
- Streams
|
|
42
|
-
- Runs as a Python CLI or
|
|
43
|
+
- Streams large recordings, subject to processing limits and available device resources (see the limit options below). zstd and lz4 chunks are decoded with bounded output.
|
|
44
|
+
- Runs as a Python CLI or in your browser at **[backplanerobotics.com/tracecheck](https://backplanerobotics.com/tracecheck/)**, where recording files are processed on your device and not uploaded.
|
|
43
45
|
|
|
44
46
|
Built by [Backplane Robotics](https://backplanerobotics.com).
|
|
45
47
|
|
|
@@ -61,6 +63,9 @@ tracecheck validate-contract examples/demo-contract.json
|
|
|
61
63
|
tracecheck check examples/clean.mcap --contract examples/demo-contract.json --out reports/clean
|
|
62
64
|
tracecheck check examples/faults.mcap --contract examples/demo-contract.json --out reports/faults
|
|
63
65
|
|
|
66
|
+
# A ROS 2 bag folder (metadata.yaml + split .mcap files), checked as one recording
|
|
67
|
+
tracecheck check examples/fleet-bag --contract examples/fleet-contract.json --out reports/fleet-bag
|
|
68
|
+
|
|
64
69
|
# Optional local browser UI (binds to 127.0.0.1 only)
|
|
65
70
|
tracecheck serve --open
|
|
66
71
|
```
|
|
@@ -71,7 +76,7 @@ tracecheck serve --open
|
|
|
71
76
|
|
|
72
77
|
| Option | Effect |
|
|
73
78
|
|---|---|
|
|
74
|
-
| `--fast` | Read only the summary section: inventory, counts, schemas and metadata in milliseconds. Timing checks (C06–C10) skip. Falls back to a full scan if the file has no usable summary. |
|
|
79
|
+
| `--fast` | Read only the summary section: inventory, counts, schemas and metadata in milliseconds. Timing checks (C06–C10) skip. Falls back to a full scan if the file has no usable summary (for a bag folder, if any file has none, the whole folder is scanned in full). |
|
|
75
80
|
| `--ignore-missing-crc` | Don't warn when the writer stored no CRCs (same as `"missing_crc": "ignore"` in the contract). Corrupt CRCs still fail. |
|
|
76
81
|
| `--fail-on fail` | Exit 0 on warnings, exit 1 only on failures (the default `warn` also exits 1 on warnings). |
|
|
77
82
|
| `--timeout SECONDS` | Stop a scan that takes too long. |
|
|
@@ -80,13 +85,28 @@ tracecheck serve --open
|
|
|
80
85
|
**Exit codes**
|
|
81
86
|
- `0`: overall pass.
|
|
82
87
|
- `1`: contract failures, warnings or an incomplete scan (all recorded in the report).
|
|
83
|
-
- `2`: configuration, input or operational error. No report is written.
|
|
88
|
+
- `2`: configuration, input or operational error, including a bag folder that can't be checked (for example, sqlite3 storage or rosbag2 file compression). No report is written.
|
|
89
|
+
|
|
90
|
+
## Check a copy after transfer
|
|
91
|
+
|
|
92
|
+
Write a manifest where the recording was made, then check the copy after upload, sync or archiving:
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
tracecheck manifest examples/fleet-bag --out fleet-bag.manifest.json
|
|
96
|
+
# ...copy the folder and the manifest somewhere else, then (replace the path with your copy's location):
|
|
97
|
+
tracecheck verify /mnt/archive/fleet-bag --manifest fleet-bag.manifest.json
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
The manifest is JSON. It holds each file's size and SHA-256 (for a bag folder, every file in the folder, including `metadata.yaml`), plus the message count per topic. `verify` reports each file as `MATCH`, `CHANGED`, `MISSING` or `EXTRA`, and compares the topic counts. Exit `0` means every file matches, `1` means something differs, `2` means an error such as an invalid manifest. `--json FILE` also writes the result as JSON. Output files are never overwritten.
|
|
101
|
+
|
|
102
|
+
A matching SHA-256 shows that the copy has the same bytes as the files the manifest was written from. It does not show who made the recording, when, or that its contents are true. The manifest is not signed, so keep it somewhere the copy's handlers can't change it.
|
|
84
103
|
|
|
85
104
|
## In the browser
|
|
86
105
|
|
|
87
106
|
[backplanerobotics.com/tracecheck](https://backplanerobotics.com/tracecheck/) runs the same checks in a Web Worker, using a JavaScript port of the engine in [`web/src/engine/`](https://github.com/backplane-robotics/backplane-tracecheck/tree/main/web/src/engine).
|
|
88
|
-
- The file is read locally in slices and
|
|
89
|
-
- The site's Content-Security-Policy
|
|
107
|
+
- The recording file is read locally in slices and not uploaded.
|
|
108
|
+
- The site's Content-Security-Policy only allows connections back to the site itself.
|
|
109
|
+
- An optional **Send feedback** form posts only the fields shown in it to `/api/feedback`. It never attaches recordings, reports, contracts or filenames. See [docs/FEEDBACK.md](https://github.com/backplane-robotics/backplane-tracecheck/blob/main/docs/FEEDBACK.md).
|
|
90
110
|
- For the same inputs, the browser and CLI produce identical JSON reports, apart from timestamps and tool fields. The web test suite checks this.
|
|
91
111
|
|
|
92
112
|
## A minimal contract
|
|
@@ -103,11 +123,11 @@ tracecheck serve --open
|
|
|
103
123
|
|
|
104
124
|
Start minimal, then read the report's channel inventory to see the actual schema names, encodings and fingerprints. Add only the requirements you can justify. See [docs/CONTRACT_REFERENCE.md](https://github.com/backplane-robotics/backplane-tracecheck/blob/main/docs/CONTRACT_REFERENCE.md) for every key.
|
|
105
125
|
|
|
106
|
-
## The
|
|
126
|
+
## The checks
|
|
107
127
|
|
|
108
128
|
| ID | Check |
|
|
109
129
|
|---|---|
|
|
110
|
-
| C01 | Readable bounded MCAP scan (with CRC verification where present) |
|
|
130
|
+
| C01 | Readable bounded MCAP scan (with CRC verification where present, and summary index agreement) |
|
|
111
131
|
| C02 | Required topics contain messages |
|
|
112
132
|
| C03 | Profile, schema and encoding |
|
|
113
133
|
| C04 | Required file metadata |
|
|
@@ -117,6 +137,7 @@ Start minimal, then read the report's channel inventory to see the actual schema
|
|
|
117
137
|
| C08 | Record-order timestamp regressions |
|
|
118
138
|
| C09 | Sequence continuity |
|
|
119
139
|
| C10 | Expected interval coverage |
|
|
140
|
+
| C11 | ROS 2 bag metadata agreement (bag folders only) |
|
|
120
141
|
|
|
121
142
|
**Statuses**
|
|
122
143
|
- **PASS:** the configured requirement was met.
|
|
@@ -124,7 +145,7 @@ Start minimal, then read the report's channel inventory to see the actual schema
|
|
|
124
145
|
- **FAIL:** an unmet requirement or a failed scan. It does not mean the robot is unsafe.
|
|
125
146
|
- **SKIPPED:** no conclusion was reached.
|
|
126
147
|
|
|
127
|
-
Tracecheck does not certify safety, establish regulatory compliance, determine causality or measure transport latency.
|
|
148
|
+
Tracecheck does not certify safety, establish legal or regulatory compliance, determine causality or measure transport latency. File hashes in reports identify the exact bytes checked; they do not establish authenticity.
|
|
128
149
|
|
|
129
150
|
## Development
|
|
130
151
|
|
|
@@ -148,7 +169,7 @@ cd web
|
|
|
148
169
|
npm install
|
|
149
170
|
npm test # engine parity tests against examples/ and the Python engine
|
|
150
171
|
npm run dev # local dev server
|
|
151
|
-
npm run build # static site in web/dist (
|
|
172
|
+
npm run build # static site in web/dist (deployed by Cloudflare Workers, see wrangler.jsonc)
|
|
152
173
|
```
|
|
153
174
|
|
|
154
175
|
## Repository layout
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
# Backplane Tracecheck
|
|
2
2
|
|
|
3
|
-
**Check robot recordings against an explicit recording contract
|
|
3
|
+
**Vendor-neutral recording integrity checks.** Check robot recordings against an explicit recording contract.
|
|
4
4
|
|
|
5
|
-
Tracecheck reads an [MCAP](https://mcap.dev) recording (the default ROS 2 bag format) and checks it against a small JSON *recording contract*: which topics must be present, their schemas and encodings, message counts, rates, timestamp gaps, regressions, sequence continuity and time coverage. It produces a JSON report and a readable HTML report.
|
|
5
|
+
Tracecheck reads an [MCAP](https://mcap.dev) recording (the default ROS 2 bag format) and checks it against a small JSON *recording contract*: which topics must be present, their schemas and encodings, message counts, rates, timestamp gaps, regressions, sequence continuity and time coverage. It produces a JSON report and a readable HTML report. Findings include relevant file locations where available; missing items are reported as gaps.
|
|
6
6
|
|
|
7
7
|
- Free and open source (Apache-2.0).
|
|
8
|
-
- Read-only. Message payloads are never decoded
|
|
8
|
+
- Read-only. Message payloads are never executed, and are not decoded, with one narrow exception: from recognised recorder event messages (rosbag2_dynamic_recorder pause and topic events) only the action and topic name are read.
|
|
9
|
+
- Gaps covered by a pause or topic change that the recorder wrote into the recording are listed as explained instead of failing. The events are the recorder's own account; Tracecheck does not verify them.
|
|
10
|
+
- Checks a ROS 2 bag folder (`metadata.yaml` plus split `.mcap` files) as one recording: gaps and sequence breaks across file boundaries count, and the counts in `metadata.yaml` are compared with what the files contain (C11).
|
|
9
11
|
- No robot, ROS install, account or cloud service needed.
|
|
10
|
-
- Streams
|
|
11
|
-
- Runs as a Python CLI or
|
|
12
|
+
- Streams large recordings, subject to processing limits and available device resources (see the limit options below). zstd and lz4 chunks are decoded with bounded output.
|
|
13
|
+
- Runs as a Python CLI or in your browser at **[backplanerobotics.com/tracecheck](https://backplanerobotics.com/tracecheck/)**, where recording files are processed on your device and not uploaded.
|
|
12
14
|
|
|
13
15
|
Built by [Backplane Robotics](https://backplanerobotics.com).
|
|
14
16
|
|
|
@@ -30,6 +32,9 @@ tracecheck validate-contract examples/demo-contract.json
|
|
|
30
32
|
tracecheck check examples/clean.mcap --contract examples/demo-contract.json --out reports/clean
|
|
31
33
|
tracecheck check examples/faults.mcap --contract examples/demo-contract.json --out reports/faults
|
|
32
34
|
|
|
35
|
+
# A ROS 2 bag folder (metadata.yaml + split .mcap files), checked as one recording
|
|
36
|
+
tracecheck check examples/fleet-bag --contract examples/fleet-contract.json --out reports/fleet-bag
|
|
37
|
+
|
|
33
38
|
# Optional local browser UI (binds to 127.0.0.1 only)
|
|
34
39
|
tracecheck serve --open
|
|
35
40
|
```
|
|
@@ -40,7 +45,7 @@ tracecheck serve --open
|
|
|
40
45
|
|
|
41
46
|
| Option | Effect |
|
|
42
47
|
|---|---|
|
|
43
|
-
| `--fast` | Read only the summary section: inventory, counts, schemas and metadata in milliseconds. Timing checks (C06–C10) skip. Falls back to a full scan if the file has no usable summary. |
|
|
48
|
+
| `--fast` | Read only the summary section: inventory, counts, schemas and metadata in milliseconds. Timing checks (C06–C10) skip. Falls back to a full scan if the file has no usable summary (for a bag folder, if any file has none, the whole folder is scanned in full). |
|
|
44
49
|
| `--ignore-missing-crc` | Don't warn when the writer stored no CRCs (same as `"missing_crc": "ignore"` in the contract). Corrupt CRCs still fail. |
|
|
45
50
|
| `--fail-on fail` | Exit 0 on warnings, exit 1 only on failures (the default `warn` also exits 1 on warnings). |
|
|
46
51
|
| `--timeout SECONDS` | Stop a scan that takes too long. |
|
|
@@ -49,13 +54,28 @@ tracecheck serve --open
|
|
|
49
54
|
**Exit codes**
|
|
50
55
|
- `0`: overall pass.
|
|
51
56
|
- `1`: contract failures, warnings or an incomplete scan (all recorded in the report).
|
|
52
|
-
- `2`: configuration, input or operational error. No report is written.
|
|
57
|
+
- `2`: configuration, input or operational error, including a bag folder that can't be checked (for example, sqlite3 storage or rosbag2 file compression). No report is written.
|
|
58
|
+
|
|
59
|
+
## Check a copy after transfer
|
|
60
|
+
|
|
61
|
+
Write a manifest where the recording was made, then check the copy after upload, sync or archiving:
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
tracecheck manifest examples/fleet-bag --out fleet-bag.manifest.json
|
|
65
|
+
# ...copy the folder and the manifest somewhere else, then (replace the path with your copy's location):
|
|
66
|
+
tracecheck verify /mnt/archive/fleet-bag --manifest fleet-bag.manifest.json
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
The manifest is JSON. It holds each file's size and SHA-256 (for a bag folder, every file in the folder, including `metadata.yaml`), plus the message count per topic. `verify` reports each file as `MATCH`, `CHANGED`, `MISSING` or `EXTRA`, and compares the topic counts. Exit `0` means every file matches, `1` means something differs, `2` means an error such as an invalid manifest. `--json FILE` also writes the result as JSON. Output files are never overwritten.
|
|
70
|
+
|
|
71
|
+
A matching SHA-256 shows that the copy has the same bytes as the files the manifest was written from. It does not show who made the recording, when, or that its contents are true. The manifest is not signed, so keep it somewhere the copy's handlers can't change it.
|
|
53
72
|
|
|
54
73
|
## In the browser
|
|
55
74
|
|
|
56
75
|
[backplanerobotics.com/tracecheck](https://backplanerobotics.com/tracecheck/) runs the same checks in a Web Worker, using a JavaScript port of the engine in [`web/src/engine/`](https://github.com/backplane-robotics/backplane-tracecheck/tree/main/web/src/engine).
|
|
57
|
-
- The file is read locally in slices and
|
|
58
|
-
- The site's Content-Security-Policy
|
|
76
|
+
- The recording file is read locally in slices and not uploaded.
|
|
77
|
+
- The site's Content-Security-Policy only allows connections back to the site itself.
|
|
78
|
+
- An optional **Send feedback** form posts only the fields shown in it to `/api/feedback`. It never attaches recordings, reports, contracts or filenames. See [docs/FEEDBACK.md](https://github.com/backplane-robotics/backplane-tracecheck/blob/main/docs/FEEDBACK.md).
|
|
59
79
|
- For the same inputs, the browser and CLI produce identical JSON reports, apart from timestamps and tool fields. The web test suite checks this.
|
|
60
80
|
|
|
61
81
|
## A minimal contract
|
|
@@ -72,11 +92,11 @@ tracecheck serve --open
|
|
|
72
92
|
|
|
73
93
|
Start minimal, then read the report's channel inventory to see the actual schema names, encodings and fingerprints. Add only the requirements you can justify. See [docs/CONTRACT_REFERENCE.md](https://github.com/backplane-robotics/backplane-tracecheck/blob/main/docs/CONTRACT_REFERENCE.md) for every key.
|
|
74
94
|
|
|
75
|
-
## The
|
|
95
|
+
## The checks
|
|
76
96
|
|
|
77
97
|
| ID | Check |
|
|
78
98
|
|---|---|
|
|
79
|
-
| C01 | Readable bounded MCAP scan (with CRC verification where present) |
|
|
99
|
+
| C01 | Readable bounded MCAP scan (with CRC verification where present, and summary index agreement) |
|
|
80
100
|
| C02 | Required topics contain messages |
|
|
81
101
|
| C03 | Profile, schema and encoding |
|
|
82
102
|
| C04 | Required file metadata |
|
|
@@ -86,6 +106,7 @@ Start minimal, then read the report's channel inventory to see the actual schema
|
|
|
86
106
|
| C08 | Record-order timestamp regressions |
|
|
87
107
|
| C09 | Sequence continuity |
|
|
88
108
|
| C10 | Expected interval coverage |
|
|
109
|
+
| C11 | ROS 2 bag metadata agreement (bag folders only) |
|
|
89
110
|
|
|
90
111
|
**Statuses**
|
|
91
112
|
- **PASS:** the configured requirement was met.
|
|
@@ -93,7 +114,7 @@ Start minimal, then read the report's channel inventory to see the actual schema
|
|
|
93
114
|
- **FAIL:** an unmet requirement or a failed scan. It does not mean the robot is unsafe.
|
|
94
115
|
- **SKIPPED:** no conclusion was reached.
|
|
95
116
|
|
|
96
|
-
Tracecheck does not certify safety, establish regulatory compliance, determine causality or measure transport latency.
|
|
117
|
+
Tracecheck does not certify safety, establish legal or regulatory compliance, determine causality or measure transport latency. File hashes in reports identify the exact bytes checked; they do not establish authenticity.
|
|
97
118
|
|
|
98
119
|
## Development
|
|
99
120
|
|
|
@@ -117,7 +138,7 @@ cd web
|
|
|
117
138
|
npm install
|
|
118
139
|
npm test # engine parity tests against examples/ and the Python engine
|
|
119
140
|
npm run dev # local dev server
|
|
120
|
-
npm run build # static site in web/dist (
|
|
141
|
+
npm run build # static site in web/dist (deployed by Cloudflare Workers, see wrangler.jsonc)
|
|
121
142
|
```
|
|
122
143
|
|
|
123
144
|
## Repository layout
|
|
@@ -24,9 +24,9 @@ Contracts are UTF-8 JSON objects up to 64 KiB. Keys are case-sensitive; duplicat
|
|
|
24
24
|
| `min_count`, `max_count` | Optional inclusive integer bounds, applied independently to every matching channel. |
|
|
25
25
|
| `time_basis` | `log_time` (default) or `publish_time`. These are MCAP Message fields, not decoded ROS header stamps. |
|
|
26
26
|
| `clock_confirmed` | Boolean, default false. All four timing checks skip unless true. User asserts the clock is interpretable for this requirement. |
|
|
27
|
-
| `min_rate_hz`, `max_rate_hz` | Optional inclusive bounds for observed average `(N−1)/(last−first)` after sorting. Not windowed rate or proof of session completeness. Use interval/gap checks too. |
|
|
28
|
-
| `max_gap_ns` | Optional inclusive upper limit between adjacent **sorted** timestamps. Does not include leading/trailing gaps. |
|
|
29
|
-
| `check_regression` | Boolean, default false. Strict decreases in **physical record order** fail; equal timestamps pass. |
|
|
27
|
+
| `min_rate_hz`, `max_rate_hz` | Optional inclusive bounds for observed average `(N−1)/(last−first)` after sorting. Not windowed rate or proof of session completeness. Use interval/gap checks too. On the `log_time` basis, if the recording contains rosbag2_dynamic_recorder pause or unsubscribe events, time covered by them is left out: the bounds are applied to `active_hz`, and the finding also reports `observed_hz` (whole span), `excluded_ns` and `excluded_by`. The events are the recorder's own account and are not verified. |
|
|
28
|
+
| `max_gap_ns` | Optional inclusive upper limit between adjacent **sorted** timestamps. Does not include leading/trailing gaps. On the `log_time` basis, a gap covered by a rosbag2_dynamic_recorder pause or unsubscribe event in the recording is listed under `explained_gaps` and does not fail, provided no uncovered part of the gap exceeds the limit. |
|
|
29
|
+
| `check_regression` | Boolean, default false. Strict decreases in **physical record order** fail; equal timestamps pass. When there are regressions, the C08 finding also reports `largest_regression_ns` and the message pair where the largest backwards jump happened (`largest_regression`), to help tell small reordering jitter from a clock reset. |
|
|
30
30
|
| `sequence` | `disabled` (default) or `increment_mod32`. The latter asserts one unit-incrementing sequence source per channel, allowing wrap from 2^32−1 to 0; resets, duplicates and jumps fail. |
|
|
31
31
|
| `interval_ns` | Optional inclusive `[start,end]`, with start < end, on the selected clock. All recorded timestamps must be inside; first and last must reach the respective boundaries within tolerance. |
|
|
32
32
|
| `boundary_tolerance_ns` | Nonnegative integer, default 0; at most half the interval length. |
|
|
@@ -35,7 +35,7 @@ Omit rate/gap/interval/sequence requirements if their assumptions are unavailabl
|
|
|
35
35
|
|
|
36
36
|
Multiple channels sharing a topic remain separate. A required topic can be present while one of its channels fails its count/encoding/timing requirement. This conservative behavior can produce findings for a zero-message channel; adapt the contract or investigate the recording rather than assuming channels share publishers or clocks.
|
|
37
37
|
|
|
38
|
-
Absence has different meanings: required missing topic fails C02, while dependent channel checks skip because there is no channel to inspect. If the overall scan fails, C02–C10 all skip and C01 fails. If no requirement applies to a check, it skips. Skipped results do not establish health.
|
|
38
|
+
Absence has different meanings: required missing topic fails C02, while dependent channel checks skip because there is no channel to inspect. If the overall scan fails, C02–C10 all skip and C01 fails. If no requirement applies to a check, it skips. Skipped results do not establish health. C11 applies only to bag folders (see below).
|
|
39
39
|
|
|
40
40
|
The JSON report embeds the complete contract and hashes its normalized UTF-8 JSON (`sort_keys=True`, compact separators, Unicode preserved). The contract hash identifies effective content rather than the original indentation/byte layout. Reports also include the source byte SHA-256 and tool/reader/Python versions. Contracts and schema bytes are not executed.
|
|
41
41
|
|
|
@@ -44,5 +44,33 @@ The JSON report embeds the complete contract and hashes its normalized UTF-8 JSO
|
|
|
44
44
|
- **Full scan** (default) streams the whole file. It computes the file SHA-256 and verifies every CRC that is present: the data-section CRC in the Data End record, each chunk's CRC of its uncompressed records, and the summary CRC in the footer. Attachment CRCs are not checked. Attachments and unknown record types are hashed but skipped.
|
|
45
45
|
- **CRC coverage rule.** C01 warns about missing CRCs only when the data-section CRC is absent **and** some message data is not covered by another CRC: a chunk without a CRC, or a message outside any chunk. Default ROS 2 recordings, with chunk CRCs but no data-section CRC, therefore pass. Set `missing_crc` to `"ignore"` to suppress the warning entirely.
|
|
46
46
|
- **Compression.** Chunks may be uncompressed, `zstd` or `lz4`. Decompressed output is capped at the chunk's declared uncompressed size. A mismatch, any other codec, or a chunk above the size limit fails C01.
|
|
47
|
-
- **
|
|
47
|
+
- **Summary index agreement** (full scan). Other tools often jump through the summary section's indexes instead of reading the whole file. C01 therefore checks that every Chunk, Attachment and Metadata index entry points to a record of that type and length (for chunks, also the compression, sizes and time range), that an index covers every record of its type, and that the Statistics record agrees with the counts and times actually read. A disagreement **warns**, listing each entry (`index`, `entry`, `offset`, `length`, `problem`) or statistic (`field`, `claimed`, `observed`); the records themselves were read directly, so the other checks are unaffected. A writer bug of this kind was fixed in MCAP TypeScript 2.4.0. A file with no indexes and no Statistics gets a *skipped* finding (no conclusion), not a failure. The finding reports `summary_index`, `index_entries_checked` and `summary_statistics`.
|
|
48
|
+
- **Fast mode** (`--fast` in the CLI, the toggle in the web app) reads only the header, footer and summary section (Statistics, Channel, Schema and indexed Metadata records) and checks the summary CRC. C01–C05 run on that information; C06–C10 skip because they need every timestamp. If the summary is missing or lacks Statistics, or its metadata index does not point to a Metadata record, the scan falls back to a full scan and records `fast_mode_fallback` in the report. In fast mode `source.sha256` is `null`.
|
|
48
49
|
- **Limits.** Defaults: 256 MiB per record, uncompressed chunk and summary section; 20 million tracked timestamps for sorted-gap checks; 10,000 schemas/channels/metadata records. Exceeding a limit fails C01 with an explanation, rather than exhausting memory. The CLI exposes `--max-chunk-mib`, `--max-record-mib`, `--max-tracked-messages` and `--timeout`. There is no overall file-size cap.
|
|
50
|
+
|
|
51
|
+
## ROS 2 bag folders (C11)
|
|
52
|
+
|
|
53
|
+
A rosbag2 recording can be a folder holding `metadata.yaml` and several `.mcap` files, split by size or duration. `tracecheck check <folder>` (or *Choose a bag folder* / dropping a folder in the web app) checks it as **one recording**. Only the folder's own files are read; subfolders are ignored.
|
|
54
|
+
|
|
55
|
+
- **Which files.** With a readable `metadata.yaml`, the files are those it lists, in its order. Without one, every `.mcap` in the folder is used, in natural name order (`b_2` before `b_10`). An `.mcap` that is present but not listed is not scanned.
|
|
56
|
+
- **One recording.** Channels from different files are matched by topic, message encoding and schema (name, encoding and bytes) and treated as one channel, so C05–C10 count gaps, regressions and sequence breaks across file boundaries. Finding locations in a bag report include a `file` key.
|
|
57
|
+
- **Not supported.** Bags with non-MCAP storage (for example `sqlite3`) or rosbag2 file compression (`compression_mode: FILE`) are refused with exit code 2. More than 1,000 files is also refused. Per-message compression inside MCAP chunks is fine.
|
|
58
|
+
- **`metadata.yaml`** is read with a small, bounded YAML-subset parser (up to 1 MiB) that covers what rosbag2 writes. Anything else is reported as unreadable rather than guessed at.
|
|
59
|
+
|
|
60
|
+
C11 *ROS 2 bag metadata agreement* compares the folder and the scan with `metadata.yaml`:
|
|
61
|
+
|
|
62
|
+
| Situation | Result |
|
|
63
|
+
|---|---|
|
|
64
|
+
| `metadata.yaml` read | pass finding |
|
|
65
|
+
| `metadata.yaml` absent or unreadable | warn (rosbag2 writes it when a recording is closed; files were taken by name) |
|
|
66
|
+
| A listed file is not in the folder | fail; C02–C10 skip and the scan is incomplete |
|
|
67
|
+
| An `.mcap` in the folder is not listed | warn; that file is not checked |
|
|
68
|
+
| Per-file, per-topic and total message counts | pass if equal to `metadata.yaml`, fail if not |
|
|
69
|
+
| A topic has messages but is not listed | warn |
|
|
70
|
+
| Scan incomplete | count comparisons skip |
|
|
71
|
+
|
|
72
|
+
In fast mode the counts come from each file's Statistics record. If any file has no usable summary, the whole folder is scanned in full and `fast_mode_fallback` names that file.
|
|
73
|
+
|
|
74
|
+
If a file ends before its MCAP footer, C01 fails, later files are not scanned, and `recovered` reports what was readable across the bag, with `incomplete_file` naming that file. The files alone cannot show why it is incomplete.
|
|
75
|
+
|
|
76
|
+
Bag reports add a `bag` section: `folder`, `metadata` (`present`, `absent` or `unreadable`), `metadata_sha256`, and, when read, `ros_distro`, `storage_identifier`, `message_count_claimed` and `topics_claimed`. `bag.files` lists each file with `listed`, `present`, `messages_claimed`, `bytes`, `sha256`, `scan` (`complete`, `summary only`, `incomplete`, `error`, `not scanned`, `missing` or `not listed`) and `messages`. In a bag report `source.sha256` is `null`; each file's hash is in `bag.files`. A hash identifies the bytes that were read; it does not show where they came from.
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Updating the FCC Covered List robot tracker
|
|
2
|
+
|
|
3
|
+
The tracker page (`/tools/covered-list-robots/`) is updated **manually**. Nothing fetches FCC data automatically:
|
|
4
|
+
fcc.gov blocks automated requests, and every entry should be checked by a person before it is published.
|
|
5
|
+
|
|
6
|
+
All content lives in one file: [`web/public/data/covered-list-robots.json`](../web/public/data/covered-list-robots.json).
|
|
7
|
+
|
|
8
|
+
## When to check
|
|
9
|
+
|
|
10
|
+
- When a news brief or law-firm alert mentions a new robotics conditional approval.
|
|
11
|
+
- About once a week, open the official list: <https://www.fcc.gov/supplychain/coveredlist>. Its "Robotic Devices
|
|
12
|
+
Conditional Approvals" table (Appendix B of each new Public Notice) lists every approval with its date.
|
|
13
|
+
|
|
14
|
+
## Adding or verifying an entry
|
|
15
|
+
|
|
16
|
+
1. Download the Public Notice PDF from FCC EDOCS (for example `DA-26-996A1.pdf`). Keep it in the project root; PDF
|
|
17
|
+
files are git-ignored everywhere in the repository and are never committed.
|
|
18
|
+
2. Add or edit the entry in the JSON file:
|
|
19
|
+
- `id`: short lowercase name, letters, digits and hyphens (for example `acme-x100`). Must be unique.
|
|
20
|
+
- `manufacturer`, `equipment` (list the models exactly as the FCC names them), `category`, `status`.
|
|
21
|
+
- `notice_number` (for example `DA 26-1114`) and `date_announced` (`YYYY-MM-DD`).
|
|
22
|
+
- `conditions_summary`: quote or closely paraphrase the notice. Don't add interpretation.
|
|
23
|
+
- `primary_source_url`: the FCC PDF link (`https://docs.fcc.gov/public/attachments/DA-26-XXXXA1.pdf`).
|
|
24
|
+
- `secondary_sources`: optional list of `https://` links (press releases, law-firm notes).
|
|
25
|
+
- `verified_against_primary`: `true` only after every field has been checked against the FCC notice.
|
|
26
|
+
- `last_checked`: the date you checked it.
|
|
27
|
+
3. Set the top-level `last_updated` to today.
|
|
28
|
+
4. Run the checks: `cd web`, then `npm test`. The test suite rejects malformed entries, duplicate IDs, bad dates and
|
|
29
|
+
non-https links. The page also refuses to show data that fails validation.
|
|
30
|
+
5. Commit, then deploy when approved.
|
|
31
|
+
|
|
32
|
+
## Scope
|
|
33
|
+
|
|
34
|
+
List robotic-device approvals only. Routers, drones (UAS) and power inverters appear in the same notices but are out of
|
|
35
|
+
scope. Keep the disclaimer text unchanged unless it has been reviewed.
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# Feedback endpoint
|
|
2
|
+
|
|
3
|
+
The Tracecheck web app has an optional **Send feedback** dialog. It is separate from recording processing:
|
|
4
|
+
recordings are checked in the browser and are never sent to this endpoint.
|
|
5
|
+
|
|
6
|
+
## What is sent and stored
|
|
7
|
+
|
|
8
|
+
The browser sends a JSON body with exactly four fields to `POST /api/feedback` on the same origin:
|
|
9
|
+
|
|
10
|
+
| Field | Values |
|
|
11
|
+
|---|---|
|
|
12
|
+
| `type` | `did_not_work`, `improvement` or `experience` (required) |
|
|
13
|
+
| `helped` | `yes`, `partly`, `no`, `not_sure` or `null` (optional) |
|
|
14
|
+
| `message` | Plain text, 1 to 2,000 characters after trimming |
|
|
15
|
+
| `app_version` | The visible app version, for example `0.2.0` |
|
|
16
|
+
|
|
17
|
+
The Worker ([`web/worker/feedback.js`](../web/worker/feedback.js)) validates the body against the shared schema
|
|
18
|
+
([`web/src/feedback-schema.js`](../web/src/feedback-schema.js)). It rejects unexpected fields, invalid values,
|
|
19
|
+
non-JSON requests, bodies over 16 KiB and cross-site requests. If validation passes, it stores one Workers KV entry:
|
|
20
|
+
|
|
21
|
+
```json
|
|
22
|
+
{ "received_at": "2026-10-18T12:00:00.000Z", "type": "improvement", "helped": "partly", "message": "...", "app_version": "0.2.0" }
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
Key format: `feedback:<received_at>:<random UUID>`. No IP address, user agent, cookie, filename, scan result or
|
|
26
|
+
other identifier is stored. The client only shows success after the Worker returns `201 {"ok": true}`, which happens
|
|
27
|
+
only after the KV write has completed.
|
|
28
|
+
|
|
29
|
+
## Privacy controls
|
|
30
|
+
|
|
31
|
+
- **No application logging.** The Worker has no `console` calls. Workers invocation logs are disabled in
|
|
32
|
+
`wrangler.jsonc` (`observability.logs.invocation_logs: false`).
|
|
33
|
+
- **Rate limiting.** 5 submissions per minute per client, using the Cloudflare Workers rate-limiting binding.
|
|
34
|
+
The client IP is the in-memory counter key and is not written to storage.
|
|
35
|
+
- **Spam control.** Only same-origin browser requests are accepted (`Sec-Fetch-Site: same-origin`, or a matching
|
|
36
|
+
`Origin`). Together with the rate limit, this is the only spam control. There is no CAPTCHA or third-party script.
|
|
37
|
+
- **No public listing.** The Worker exposes no read or list endpoint. Any other `/api/*` path returns 404.
|
|
38
|
+
- **Provider logs.** Cloudflare may still keep its own edge and security logs for requests to the site.
|
|
39
|
+
Check the current Cloudflare dashboard settings and policies before making stronger statements.
|
|
40
|
+
|
|
41
|
+
## Retention
|
|
42
|
+
|
|
43
|
+
Each entry is written with a KV `expirationTtl` of 90 days, after which Cloudflare deletes it.
|
|
44
|
+
|
|
45
|
+
> Do not advertise the 90-day period on the website until expiry has been confirmed on the production namespace.
|
|
46
|
+
> For example, write a test entry with a short TTL using
|
|
47
|
+
> `npx wrangler kv key put --binding FEEDBACK --remote "feedback:ttl-test" "{}" --ttl 60`, then confirm it is gone
|
|
48
|
+
> a few minutes later.
|
|
49
|
+
|
|
50
|
+
## One-time setup (owner)
|
|
51
|
+
|
|
52
|
+
Run these from the repository root with your Cloudflare account. Workers KV and the rate-limiting binding are both
|
|
53
|
+
available on the free plan.
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
cd web && npm ci && cd ..
|
|
57
|
+
npx --prefix web wrangler login
|
|
58
|
+
npx --prefix web wrangler kv namespace create FEEDBACK
|
|
59
|
+
# Copy the printed id into wrangler.jsonc, replacing REPLACE_WITH_FEEDBACK_KV_NAMESPACE_ID.
|
|
60
|
+
cd web && npm run build && cd ..
|
|
61
|
+
npx --prefix web wrangler deploy
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
Until the placeholder id is replaced, `wrangler deploy` fails. That stops the site from being deployed with a
|
|
65
|
+
feedback button that cannot store anything.
|
|
66
|
+
|
|
67
|
+
## Reading feedback privately
|
|
68
|
+
|
|
69
|
+
Feedback is read only through the authenticated Cloudflare dashboard or the CLI:
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
npx --prefix web wrangler kv key list --binding FEEDBACK --remote
|
|
73
|
+
npx --prefix web wrangler kv key get --binding FEEDBACK --remote "feedback:2026-10-18T12:00:00.000Z:<uuid>"
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
Treat the message text as untrusted. Read it as plain text and never paste it into HTML or a spreadsheet formula
|
|
77
|
+
without escaping.
|
|
78
|
+
|
|
79
|
+
## Deleting feedback
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
npx --prefix web wrangler kv key delete --binding FEEDBACK --remote "<key>"
|
|
83
|
+
```
|
|
Binary file
|