Skip to content

ci(measure): rvt-info reads every model and family, and the compare job diffs it, so the PartAtom parser is measured - #538

Merged
DrunkOnJava merged 3 commits into
mainfrom
ci/measure-family-info
Sep 30, 2026
Merged

DrunkOnJava merged 3 commits into
mainfrom
ci/measure-family-info

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Sep 30, 2026 •

Copy link
Copy Markdown
Owner

Summary

The Measure workflow now has rvt-info read every reference model, and every file of the Autodesk family corpus when asked, and its compare job lists the files whose output differs between head and base. That is the first measurement of the PartAtom parser: until now a change to it, or to quick-xml, could leave every measured number identical.

Motivation

Measure scores the IFC export and the scorers under tools/re/. The export reaches the PartAtom parser only through a PartAtom stream, and none of the six reference models has one: diagnostics.json says has_part_atom: false on each of them (Core Interior, Einhoven and the four RE1 models; the artifacts of Measure run 36743387491). So the quick-xml 0.42 migration in #535 came out "IFC identical on 6 of 6" while saying nothing about the parser it changed. The parser also reads a project's ProjectInformation stream (RevitFile::document_atom, which rvt-info's document block uses), and the family corpus carries the PartAtom streams themselves, but Measure fetched the family corpus only for a probe, and only when one was named.

Changes

  • .github/workflows/measure.yml: each side builds rvt-info as well. The family corpus is fetched when families is set and on every pull-request run of the workflow itself, so its self-measurement covers it. The compare job lists, for every model and family, whether rvt-info's output and exit status are identical or differ, and skips directories with no IFC hash when it lists the IFC (a family directory has none, and cmp on a missing file counts as different).
  • tools/ci/measure-reference-models.sh: rvt-info --redact --json on every model and every family (info.json, with info.exit), --redact because the output goes into artifacts of a public run. The probe on families no longer needs a probe to be named for the rest to run.
  • CONTRIBUTING.md: what the family diff is for, the command, and how to measure a branch with a workflow file that is not on main yet (--ref <branch with the workflow> -f ref=<branch to measure>).

Testing

actionlint, shellcheck and a YAML parse are clean. The workflow measures itself on this pull request (base main, families fetched by default for pull-request runs):

  • Self-test, Measure run 36744397852 (this branch's merge commit against main aefc29f): rvt-info output and exit status are identical (exit 0) on all 17 files, the six models and the eleven families; nothing but the harness changed, so identical is the expected result, and what it shows is that the step runs and reads real content. The last commit only adds the exit status to each summary line; the compare step was run against these artifacts to see the summary it writes (six IFC hashes, then the 17 rvt-info lines, each identical (exit 0)).
  • It is not vacuous. On the eleven families the output holds a PartAtom (title 0610 x 0915mm, OmniClass 23.40.20.14.17, two categories and two taxonomies, 3.4 to 4.2 KB of XML each). On the six models there is no PartAtom stream, but document.title and last_saved, which are the entry_title and updated of the atom (2024_Core_Interior and 2023-09-07T12:50:35Z on Core Interior, for one), are set on all six, so their ProjectInformation stream does go through the same parser.
  • Used on build(deps): raise the MSRV to 1.87 and take quick-xml 0.42 and earcut 0.4.11 #535 (the quick-xml 0.41 to 0.42 migration), dispatched from this branch with -f ref=build/msrv-1-87 -f base=main -f families=true (run 36744354619): head 3561238 against main aefc29f, all 17 files identical (exit 0).

Audit-honesty checklist

  • What this does not measure: a PartAtom stream in a real project file (none of the redistributable projects has one), and anything about the eleven families beyond what rvt-info prints
  • The IFC list still says "identical" for what it compared, the export with its time lines removed; the new list says what rvt-info printed and its exit status, and nothing more
  • No emojis, private paths or PII; the family output is redacted

Legal and contribution hygiene

  • Apache-2.0
  • No Autodesk content is stored: the family corpus is fetched for the run, rvt-info prints metadata, and --redact scrubs paths and users
  • No fixtures

Breaking changes

None.

Related issues

Measures #535.

…ob diffs it, so the PartAtom parser is measured

The IFC export reaches the PartAtom parser only through a PartAtom stream,
and none of the six reference models has one (diagnostics.json says
has_part_atom false on each), so a change to the parser or to quick-xml moved
no measured number: the IFC and every scorer could stay identical while
PartAtom parsing changed. The parser also reads a project's ProjectInformation
stream, and rvt-info prints what it read, so:

- each side builds rvt-info too, and the scoring script runs
  `rvt-info --redact --json` on every model (info.json, info.exit);
- with `families=true`, and on every run of a change to the workflow itself,
  the Autodesk family corpus is fetched and each .rfa gets the same, so the
  PartAtom streams are read on eleven releases (before this, families were
  fetched only for a probe, and only when one was named);
- the compare job lists the files whose rvt-info output differs, and skips
  the directories with no IFC hash when it lists the models' IFC (a family
  directory has no hash, so `cmp` would have listed it as differing).

CONTRIBUTING.md says when to use it, and how to measure a branch with a
workflow file that is not on main yet.
@DrunkOnJava DrunkOnJava added area:ci Work in the ci area. priority:P2 Important quality, usability, or hardening work. type:ci Continuous integration or automation work. labels Sep 30, 2026
@cursor

cursor Bot commented Sep 30, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_e8f2c8ab-0d02-4234-8175-3eb42e0def16)

…l failures do not read as identical

The compare step listed a file as "identical" when head and base printed the
same JSON and the same exit line, which is also true when rvt-info fails the
same way on both sides and prints nothing. Each identical line now carries
the exit status it compared ("identical (exit 0)"), so a family or model that
rvt-info cannot read shows up as such instead of as a pass.

The step was run against the artifacts of this pull request's own Measure run
to check the summary it writes: the six models' IFC hashes, then all
seventeen rvt-info lines, each "identical (exit 0)".
DrunkOnJava added a commit that referenced this pull request Sep 30, 2026
…t 0.4.11 (#535)

## Summary

Raises the minimum supported Rust version from 1.85 to 1.87 and takes the two dependency updates that floor was holding back: quick-xml 0.42 (#532) and earcut 0.4.11 (#531). The PartAtom reader is moved to quick-xml 0.42's `&str` API, and nine remainder checks become `is_multiple_of`, which clippy asks for once the MSRV allows it. Nothing else in the crate changes.

## Motivation

Both updates need a newer compiler than 1.85. quick-xml 0.42 declares `rust-version = 1.86` (its changelog: "The MSRV has been raised to 1.86"; crates.io agrees). earcut declares no `rust-version`, but from 0.4.10 it calls `is_multiple_of`, stable from Rust 1.87 (RELEASES.md, Version 1.87.0), which is why `Cargo.toml` held it below 0.4.10 and noted "Lift the bound with the MSRV". Dependabot's own bump of that bound (to `<0.4.12`, in #531) failed the MSRV job with `use of unstable library feature unsigned_is_multiple_of`, and #532 does not compile: quick-xml 0.42 changed names, text and entity references from `&[u8]` to `&str`.

Holding both indefinitely would leave the dependency graph frozen at whatever 1.85 allows. The cost of moving is small: `rvt` on crates.io has 25 downloads and no reverse dependencies (crates.io API, 2026-09-30), and Rust 1.87 was released on 2025-05-15.

## Changes

- `Cargo.toml`, `rvt-py/Cargo.toml`, `tools/stream_evidence/Cargo.toml`: `rust-version = "1.87"`. `earcut = "0.4.5"` (the upper bound is gone), `quick-xml = "0.42"`. The criterion comment that named the 1.85 floor no longer does.
- `Cargo.lock`, `fuzz/Cargo.lock`: earcut 0.4.11 and quick-xml 0.42.0. The checksums are the ones Dependabot wrote into the fuzz lock and equal the crates.io API's for both versions; the dependency lists are unchanged.
- `src/part_atom.rs`: `e.name().into_inner()` instead of `from_utf8_lossy(e.name().as_ref())`, `a.key.into_inner() == "scheme"` instead of a byte comparison, and text and entity references read through the events' `Deref<Target = str>` (`decode()` was removed). `normalized_value`, `resolve_char_ref` and `resolve_predefined_entity` keep their signatures, and an entity reference's content is still the bare name (`amp`), as quick-xml's own doc example for `BytesRef` shows.
- `src/elem_table.rs`, `src/element_record_plan_profiles.rs`, `src/geometry/recovery.rs`, `src/ifc/gltf.rs`, `src/native_saved_mesh.rs`, `src/transmission_data.rs`: nine `x % n == 0` checks on unsigned integers become `x.is_multiple_of(n)`, each exactly the replacement clippy's `manual_is_multiple_of` printed on this pull request's first run (the lint applies from `rust-version` 1.87; the divisors are non-zero literals, so `is_multiple_of` and `%` agree).
- `.github/workflows/ci.yml`: the MSRV job builds on 1.87, so its check name is now `build + real files / ubuntu-latest / 1.87` (not a required check).
- README, CONTRIBUTING, RELEASE, AGENTS, `docs/install.md`, `docs/python.md`, `docs/benchmarks.md`, `.cursor/install.sh`, the bug report form's placeholder and the witness crate's comment: 1.87.
- `docs/maintaining.md`: a section on how the MSRV moves and what to do with a Dependabot pull request that fails the MSRV job.
- `CHANGELOG.md`.

## Testing

No product logic changes; the evidence is the build and the measurements on the runners, taken at 3561238. The branch was then brought up to date with `main`, which added only the audit tool's fix (#536), a docs table (#537) and their changelog line, and its required checks ran again.

- [x] Every check passes at 3561238, required or not: the MSRV job on 1.87 (`build + real files / ubuntu-latest / 1.87`), macOS and Windows, the wheel, `cargo bench --no-run`, corpus tier 2, the writer patch corpus, the IfcOpenShell validator and the release-binary builds.
- [x] Measure, head 3561238 against `main` aefc29f, [run 36743387491](https://github.com/DrunkOnJava/rvt-rs/actions/runs/36743387491): the IFC is byte-identical on all six reference models (Core Interior, Einhoven, RE1 Architecture, Electrical, Mechanical, Plumbing), and so is every scorer output, about twenty per model. This says nothing about the PartAtom parser: the exporter reads only a `PartAtom` stream, and `diagnostics.json` shows `has_part_atom: false` on all six.
- [x] The parser is measured by #538's addition to Measure, which has `rvt-info --redact --json` read every model and every Autodesk family and diffs it. Run from that branch on this one (head 3561238 against `main` aefc29f, `families=true`, [run 36744354619](https://github.com/DrunkOnJava/rvt-rs/actions/runs/36744354619)): the output and the exit status (0) are identical on all 17 files. On the eleven families (2016 to 2026) that is a PartAtom read through the migrated code (title `0610 x 0915mm`, OmniClass `23.40.20.14.17`, two categories and two taxonomies, 3.4 to 4.2 KB of XML each); on the six project models it is their `ProjectInformation` stream, which goes through the same `PartAtom::from_bytes` (`document.title` and `last_saved` are the atom's `entry_title` and `updated`, and are set on all six).
- [x] Fuzz, `fuzz_part_atom` for 300 s on this branch at 3561238 ([run 36744743660](https://github.com/DrunkOnJava/rvt-rs/actions/runs/36744743660)): 14,137,919 executions of `PartAtom::from_bytes` under libFuzzer, no crash, timeout or out-of-memory. The same run builds the fuzz workspace on nightly against quick-xml 0.42 and earcut 0.4.11 in `fuzz/Cargo.lock`.

## Audit-honesty checklist

- [x] The MSRV, in the manifests, CI and docs, moves together; the changelog says `rvt` 0.4.0 on crates.io still declares 1.85
- [x] Not established here: PartAtom streams other than these seventeen files. The reader is given a `&str`, so quick-xml 0.42's new rejection of input that is not valid UTF-8 cannot happen from `PartAtom::from_bytes`, which already returns an error for invalid UTF-8
- [x] No emojis, private paths or PII

## Legal and contribution hygiene

- [x] Apache-2.0
- [x] No Autodesk content
- [x] No fixtures

## Breaking changes

The minimum supported Rust version rises from 1.85 to 1.87. The next release notes carry it.

## Related issues

Supersedes the Dependabot pull request #532 (quick-xml 0.42) and the earcut part of #531.
@DrunkOnJava
DrunkOnJava enabled auto-merge (squash) September 30, 2026 16:39
@DrunkOnJava
DrunkOnJava merged commit c8433a1 into main Sep 30, 2026
24 checks passed
@DrunkOnJava
DrunkOnJava deleted the ci/measure-family-info branch September 30, 2026 16:42
DrunkOnJava added a commit that referenced this pull request Sep 30, 2026
…diff and the fuzz target, not only built

The quick-xml 0.42 migration (#535) showed that Measure's IFC hashes and
scorers never reach the PartAtom parser: no reference model has a PartAtom
stream. #538 added the rvt-info diff over the six models and the eleven
families; this says in the maintainer guide when to use it, and to dispatch
fuzz.yml on the branch for the PartAtom reader, so the next update to quick-xml,
flate2, encoding_rs or cfb is measured the way that one was.
DrunkOnJava added a commit that referenced this pull request Sep 30, 2026
…y the version (#540)

## Summary

Makes the MSRV job a required check, under a name that does not carry
the version, so a pull request that needs a newer Rust than
`rust-version` cannot merge, and an MSRV bump does not mean editing the
ruleset.

## Motivation

The MSRV job builds on the release `rust-version` names and runs the
real-file checks that need no corpus. It has been advisory, so
auto-merge and `gh pr merge` went past it: Dependabot's earcut 0.4.11
update (#531) failed it (earcut 0.4.11 needs Rust 1.87 on a 1.85 MSRV)
and GitHub still called the pull request `UNSTABLE`, not blocked.
`docs/maintaining.md` (#535) says such a pull request is not merged as
it is; this makes the ruleset say it instead of leaving it to the
maintainer's attention. The check's name embedded the version (`build +
real files / ubuntu-latest / 1.87`), which the ruleset would have to
follow at every bump; it is now `build + real files / ubuntu-latest /
msrv`.

## Changes

- `.github/workflows/ci.yml`: the matrix entry for the MSRV gets `label:
msrv`, and the job name uses `${{ matrix.label || matrix.rust }}`, so
the stable jobs keep their names and the MSRV job is `build + real files
/ ubuntu-latest / msrv`.
- `.github/rulesets/main-protection.json`: `build + real files /
ubuntu-latest / msrv` is a required status check. It is applied to the
live ruleset with the API after this merges and after the pull requests
already in flight have landed or been brought up to date, since one
whose workflow predates this change never reports the check and would
wait on it forever.
- `docs/maintaining.md`: the required checks, the MSRV section, and a
paragraph on how an update to a parser dependency is measured (the
`rvt-info` diff from #538, and `fuzz.yml` dispatched on the branch for
the PartAtom reader), which is how #535 was measured.
- `CHANGELOG.md`.

## Testing

No product code changes; `actionlint` and a YAML parse are clean.

- [x] The check `build + real files / ubuntu-latest / msrv` reports on
this pull request and passes ([job
109994622314](https://github.com/DrunkOnJava/rvt-rs/actions/runs/36746710272/job/109994622314));
the stable, macOS and Windows jobs keep their names and pass too
- Not checked by this pull request, and done after it merges: the live
ruleset is updated from the file (`gh api -X PUT
repos/DrunkOnJava/rvt-rs/rulesets/15270879 --input
.github/rulesets/main-protection.json`), and `python3
tools/maintainer/audit.py` says the live rulesets match the file

## Audit-honesty checklist

- [x] Every open pull request that predates this change lacks the new
check until it is brought up to date with `main`, and is blocked until
then; the maintainer updates them
- [x] The MSRV job builds without the corpora (`with_corpus: false`), so
it is a compile and contract check on the oldest supported Rust, not a
real-file measurement; the stable job on Linux is where the corpus is
read
- [x] No emojis, private paths or PII

## Legal and contribution hygiene

- [x] Apache-2.0
- [x] No Autodesk content
- [x] No fixtures

## Breaking changes

None for users. A contributor's pull request must pass the MSRV job to
merge.

## Related issues

Follows #535.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:ci Work in the ci area. priority:P2 Important quality, usability, or hardening work. type:ci Continuous integration or automation work.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant