Repository navigation
fix(viewer): a click picks what is drawn, and a browser test clicks a folded piece (#1422) - #1431
Merged
Merged
Conversation
DrunkOnJava
marked this pull request as ready for review
November 5, 2026 08:19
… and the office test holds its panel requests while it scans (#1422)
12 of 15 tasks
DrunkOnJava
added a commit
that referenced
this pull request
Nov 5, 2026
… lines (#421) (#1426) ## Summary Revit 2026 and 2027 projects now draw beams along their axes, stair runs and tread landings from their records, and floors, ceilings and slabs from their sketch lines, as 2024 and 2025 projects do. Five readers' release lists gain 2026 and 2027, and the Sketch curve list reader is read there too. It's a first slice of #1190, held to the same Autodesk samples saved by Revit 2024 and 2025. [Maintainer correction: the contributor's text said "sloped roofs as their planes" and "six readers"; sloped roofs are left out and the roof slope list is not widened, and a monolithic landing stays its box. See the maintainer sections below.] ## Motivation #1190 asks for each capability 2024 and 2025 have on every release from 2015 to 2027, "one capability on one release" at a time. On `main`, 2026 and 2027 already read the 2025 records (RE-124, RE-179): walls with their layers and joins, family boxes and saved meshes are the same as on 2025. Six readers were still limited to 2024 or 2025, so on 2026 and 2027 their elements were drawn as their record boxes. `exported.body_sources` on `main`: | body source | `rac_advanced` 2024 / 2025 / 2026 / 2027 | `rac_basic` 2025 / 2026 / 2027 | `rst_basic` 2024 / 2026 / 2027 | |---|---|---|---| | `partition_beam_axis` | 29 / 0 / 0 / 0 | | 345 / 0 / 0 | | `partition_beam_box_along_axis` | 8 / 0 / 0 / 0 | | 9 / 0 / 0 | | `partition_stair_run_sketch` | 5 / 10 / 0 / 0 | 2 / 0 / 0 | 1 / 0 / 0 | | `native_landing_tread` | 5 / 0 / 0 / 0 | | | | `partition_roof_slope` | 1 / 1 / 0 / 0 | | | ## Changes - `src/research/partition_beam_axes.rs`: `BEAM_AXIS_SUPPORTED_REVIT_VERSIONS` 2024 → 2024, 2026, 2027; `SKETCH_LINE_SUPPORTED_REVIT_VERSIONS` gains 2026, 2027. - `src/research/native_stairs.rs`: `NATIVE_RUN_REVIT_VERSIONS`, `NATIVE_RUN_SHAPE_REVIT_VERSIONS` gain 2026, 2027; `NATIVE_LANDING_REVIT_VERSIONS` 2024 → 2024, 2026, 2027. - `src/research/partition_roof_slopes.rs`: `ROOF_SLOPE_SUPPORTED_REVIT_VERSIONS` gained 2026, 2027 on the first head; it is 2024, 2025 again (maintainer). - `src/research/partition_schema_mvp/walls.rs`: a wall's profile openings (RE-151) checked the beam reader's list, so they now have their own, `WALL_PROFILE_OPENING_REVIT_VERSIONS` = 2024, the release they're measured on. - `tools/re/save_pair_bodies.py` (new): two rvt-rs exports of the same project, element for element by `Tag`, world box (3 mm) and volume (0.1%). - `reports/element-framing/RE-341-2026-2027-beams-stairs-roofs.md`, an addendum to `docs/format-reconnaissance.md`, `docs/status.md`, `docs/supported-profile.md`, `changelog.d/added/1190-2026-2027-beams-stairs-roofs.md`. 2025 isn't widened. Its beams and landings would change as well, and no Revit 2025 export that holds them can be published here. ## Testing Unit tests are banned in this repository: do not add them. Show the change working end to end on real files instead. - [x] `tools/check-local.sh` passes (fmt, clippy, rustdoc, build, real-file / CLI / contract checks) - `tools/check-local.sh --corpus` on the branch head, on `main` 77d71cb: passes (300 integration tests, 15 MCP). - [ ] Verified end to end on real Revit files: the command, the files (and their licence), and the measured result against Revit's own export are in the PR body, with the script or probe that reproduces it - **Not against Revit's own export:** Measured instead against the same Autodesk samples saved by 2024 and 2025, whose exports are measured against Revit's (RE-50, RE-56, #357, #824). The files are the pinned samples in `research/autodesk-sample-projects.tsv` (fetched, never stored). - Bodies these readers now draw: - `rst_basic` 2026 and 2027: 355 of 355 are the 2024 save's (345 beams by their axis, 9 along it, 1 stair run). - `rac_advanced` 2026 and 2027: 43 of 43 are the 2024 save's (37 beams, 5 tread landings, the sloped roof); 10 of 10 stair runs are the 2025 save's. [Maintainer: the sloped roof is no longer drawn on 2026 and 2027, so 42 of 42; the contributor's local figures are not re-run, and run 42016210686's check reads 42 beams and tread landings and 10 stair runs equal.] - `rac_basic` 2026 and 2027: 2 of 2 stair runs are the 2025 save's. - Every body in the file, differing from the reference save, `main` → this branch: - `rst_basic` 2026 and 2027 against 2024: 35 → 1 of 453 (the one left is a column, as on `main`). - `rac_advanced` 2026 and 2027 against 2025: 64 → 63 of 5,527. 10 stair runs become 2025's. 9 stop being 2025's and become 2024's: 2 beams and 5 landings that 2025 still draws as boxes, and a ceiling and a floor the sketch lines now draw as on 2024. - `rac_basic` 2026 and 2027 against 2025: 27 → 23 of 438. - Byte identity: of 107 local files, 101 export IFC and diagnostics byte for byte as on `main` (`SOURCE_DATE_EPOCH=1700000000`). That covers every 2015 to 2025 file: Autodesk's samples, Core Interior, the RE1 models, Einhoven, the BIM4LCA office and terrain housing, and puzzbobb's R2025 models. The 6 that change are the 2026 and 2027 saves of `rac_advanced`, `rac_basic` and `rst_basic`. - [x] If this touches the IFC exporter: the witness verdicts replay (see CONTRIBUTING.md) or the changed observations are refreshed in this PR - Core Interior (2024) exports byte for byte as on `main`, so its observations are unchanged. - [ ] If this is a performance change: reran `tools/bench.sh` and attached the before / after - N/A. ``` tools/fetch-autodesk-samples.sh samples 2024 2027 for f in samples/*.rvt; do rvt-ifc "$f" -o "${f%.rvt}.ifc"; done python3 tools/re/save_pair_bodies.py samples/2027-rstbasicsampleproject.ifc samples/2024-rstbasicsampleproject.ifc python3 tools/re/save_pair_bodies.py samples/2026-racadvancedsampleproject.ifc samples/2024-racadvancedsampleproject.ifc \ --sources partition_beam_axis,partition_beam_box_along_axis,native_landing_tread,partition_roof_slope ``` ## Audit-honesty checklist - [x] README / docs reflect the current state after this PR — no claims of features that are not actually shipped in this PR - [x] A user-visible change has its entry as a fragment under `changelog.d/<section>/` (see `changelog.d/README.md`), not in `CHANGELOG.md` - [x] If a limitation was resolved, the "Known limitations" / "What works today" section in the relevant docs is updated - `docs/supported-profile.md` (the 2026 row; 2027 is "as on 2026") and `docs/status.md`. - [x] If a new limitation was introduced, it is documented in the PR body and in-code - None new. 2025's beams and landings, and a wall's profile openings beyond 2024, are noted in the constants' docs and RE-341 §5. - [x] Commit messages describe WHAT changed and WHY, not "fix things" or "updates" - [x] No emojis in code, docs, or commit messages - [x] No private paths, personal email addresses, or internal jargon in committed files - [ ] If this is a reverse-engineering finding: a reproducible probe under `probes/examples/` and a dated addendum to `docs/format-reconnaissance.md` are included - The addendum is included. No new byte layout is decoded (the records are RE-124's and RE-179's), so there is no probe. `tools/re/save_pair_bodies.py` reproduces the measurement. ## Legal and contribution hygiene - [x] I agree this work is licensable under Apache-2.0 (see `CONTRIBUTING.md`) - [x] This PR contains no Autodesk proprietary source, decompiled internals, or NDA'd SDK content (see `CLEANROOM.md`) - [x] Any new test fixtures use synthetic values (`testuser`, `111111`, `FY-20XX`, etc.) and contain no real-world PII - No fixtures. ## Breaking changes None. Only release lists change; their public constants keep their names and types. ## Screenshots or output samples `tools/re/save_pair_bodies.py` on 2027 `rst_basic` against 2024, `main` then this branch: ``` main: same 418, differ 35, not in the reference 0 IfcBeam: same 338, differ 32, not in the reference 0 IfcColumn: same 29, differ 1, not in the reference 0 IfcFooting: same 36, differ 0, not in the reference 0 IfcMember: same 2, differ 0, not in the reference 0 IfcSlab: same 4, differ 1, not in the reference 0 IfcStairFlight: same 0, differ 1, not in the reference 0 IfcWall: same 9, differ 0, not in the reference 0 this branch: same 452, differ 1, not in the reference 0 IfcBeam: same 370, differ 0, not in the reference 0 IfcColumn: same 29, differ 1, not in the reference 0 IfcFooting: same 36, differ 0, not in the reference 0 IfcMember: same 2, differ 0, not in the reference 0 IfcSlab: same 5, differ 0, not in the reference 0 IfcStairFlight: same 1, differ 0, not in the reference 0 IfcWall: same 9, differ 0, not in the reference 0 ``` ## Related issues Refs #1190, #421 --- Maintainer note: main was merged in, and the report renumbered from RE-340 to RE-341, since RE-340 on `main` is #1401's report. No reader changed. --- ## Maintainer changes (2026-11-05) The contributor's text above is kept as written. Where it is out of date it is corrected here. Six signed commits sit on top of the PR's earlier two (the contributor's 20bc9f2, untouched, and the earlier merge of `main`): a merge of `main` (5f52be1), the code (d50d53b), `tools/re/save_pair_bodies.py` (8e2a9e4), the docs (14952a4, f903515) and a clippy range fix (f149e22). **The title still says "and sloped roofs"; sloped roofs are no longer in this PR.** It cannot be edited from the branch; retitle at the squash, for example "feat(ifc): Revit 2026 and 2027 beams, stair runs, landings and sketch lines". **Sloped roofs are left out.** `ROOF_SLOPE_SUPPORTED_REVIT_VERSIONS` is 2024 and 2025 again, so the Summary's "sloped roofs as their planes" and the Changes line for `partition_roof_slopes.rs` above no longer apply. - The source comment said `rac_advanced`'s roof is its 2025 save's; RE-341 section 3 had it right: it is its 2024 save's body (532 triangles, 5.33 m3), and the 2025 save's is 12 triangles and 6.88 m3. No Revit export scores either. - On 2026 and 2027 an edge takes the 2024 reading of its slope, and the fascia, rafter cut and several-arrow readers are 2025 only, so a roof whose eave cut cannot be told would be drawn as a plain sloped slab. - The held-out digest has no roof-body scorer line: the third held-out model's roof left the record-box set on the first head with nothing scoring what replaced it. **A Sketch's curve list (RE-97) is read on 2026 and 2027.** The beam and sketch-line lists gate the readers floors, ceilings, slabs, footprint roofs and shaft voids use, so those change on 2026 and 2027 too (named in the docs and the changelog fragment now); but the list reader stayed `2024 | 2025`, so the guard for an edited sketch could not fire there. A list is taken only where it validates (RE-97). **What the PR changes on 2026 and 2027:** beams along their axes, stair runs and landings, the stair property sets and quantities (read from native records), and the floors, ceilings, slabs, footprint roofs and shaft voids drawn from sketch lines. Unread there: sloped roofs, spiral runs, stair names, railing heights and lengths, a wall's profile openings, IFC export overrides, the opening index. **Measured (Measure run 41988011289, head 1d5bbf0, base `main` 182ed21; counts only for held-out models).** The Testing section above says no Revit 2026 or 2027 export is available; five are held out in Measure. - Of 111 exports, 102 are byte for byte `main`'s and 9 differ, all 2026 or 2027: the six Autodesk samples and three held-out models. - Held-out 2026 and 2027: one stair flight each leaves the record-box set; property values equal Revit's go 209 to 224 of 352 (2026) and of 354 (2027), quantities 21 to 23 of 322 and 17 to 19 of 367; different and values Revit does not write unchanged. - The held-out 2026 and 2027 office models are identical, so no beam or landing is scored against a Revit export. - MCP consistency: 0 differ on every line of the three held-out models that moved. IFC rule findings on the 2026 and 2027 samples are the sloped-beam ones the 2024 saves have (#1432). **Not yet measured: the current head** (roofs left out, Sketch lists on 2026 and 2027, the script's counts). Measure run 42004827803 is on f903515; a later commit (f149e22) only rewrites an OR pattern of releases as a range for clippy, so it measures the same behaviour, but the figures above are not carried to it until it is read. The section 3 figures (355 of 355, 43 of 43, 10 of 10, 2 of 2) are the contributor's local pairs; the script dropped unmeshed shapes and repeated Tags silently, so they cannot say how many bodies were never paired, and it now counts those and exits 1. --- ## Maintainer changes, round two (2026-11-05): roofs, and a check against the earlier save Head e56d31b (signed) is f149e22 plus four commits: roofs held to the record-box solve (8f10a03), the check (85c7f01), docs (a57f4f5), a style fix (e56d31b). **Measure run 42010304828** measures this head: filtered (samples on, held-out models only), dispatched from branch `fix/1426-bodies-across-saves`, because the scorers and the workflow step come from the dispatch ref. **Not read yet**; nothing below is a result of that run. **The held-out house's roof is a guess, so roofs stay out of the widened readers.** With the slope list reverted its `IfcRoof` still left the record-box list (run 42004827803, head f903515: `box bodies` 45 to 44). A roof whose slope is not read is drawn as its sketch outline at the record box's full height, a level block at the highest point, and Revit's roof volume there is 14.2% of its box, so it is very likely sloped. 2024 and 2025 ship that body for such roofs (RE-50, RE-98, #884's hips over a T or U footprint), with its slab quantities withheld unless the layers fill the body, and measured it as a plan outline against Revit's upward-face area, never as a volume. Nothing measures it on 2026 or 2027. So on 2026 and 2027 a roof takes neither the Sketch curve list nor the lines' exact ends and no shaft void is cut from it (`roof_reads_exact_sketches`): it is read as on `main`. Floors, ceilings and slabs keep the widened readers, with shaft voids cut from floors and ceilings. The roof's state on this head is not measured, and the check below does not reach held-out models. **The check.** `tools/re/bodies_across_saves.py` holds each 2026 and 2027 save of `rac_advanced`, `rac_basic` and `rst_basic` to the same project's earlier saves, matched by `Tag`: beams, landings and sketch outlines (floors, ceilings, slabs and roofs with a recovered outline, shaft voids included) to the **2024** save, stair runs to the **2025** save. The 2025 save draws no beam or landing (its body sources hold none: record boxes), so it cannot be their reference. The 2025 save reads runs from native records as 2026 and 2027 do and draws all 10 of `rac_advanced`'s and 2 of `rac_basic`'s runs; the 2024 save's byte-anchor reader draws 5 and 1. It fails on a difference in IFC class, GlobalId, storey, `BodySource`, representation types and solid kinds, placement (0.001 ft), body volume or vertices (0.001 ft, both ways); on an element with no counterpart, one the earlier save draws otherwise, one of the earlier save's missing here, a missing export, fewer bodies than the sample holds (29 axes, 8 along them, 5 landings and 10 runs on `rac_advanced`; 345, 9 and 1 on `rst_basic`; 2 runs on `rac_basic`), the ceiling 147534 or floor 139803 not compared equal, and a check that compared nothing. It prints the number compared per class and the number left as boxes (counted, not scored). Measure's sample shard keeps the 2024 to 2027 exports of the three projects until it has run, and `tools/ci/check-bodies-across-saves.sh` fails the head side's shard (after the results upload) on any failure or any sample whose file was not written. The base side is not gated: its `bodies_across_saves.txt` shows what the check says of `main`. **It cannot catch** an error the earlier save shares with the 2026 or 2027 read. `RepresentationType` is compared as written: both saves come from the same build, so #1432's change to it does not show. The fragment, status, evidence, support matrix and RE-341 say all of this. **Proof it can fail.** Not on Autodesk's files yet: that is run 42010304828. On synthetic IFC pairs made with IfcOpenShell (not committed), the identical pair passes, and each of these exits 1: a candidate beam 1 mm deeper (volume), a beam moved one metre (placement and vertices), a different `BodySource`, a slab left out of the candidate (missing element), a missing 2025 save. On `main` the 2026 and 2027 saves draw no beam, so the base side's output should fail. **Differences.** If the check finds any on the real files, the reader narrows until it is never wrong and what it leaves out stays a box, counted; none is allowlisted. **Run 42004827803 figures** (head f903515, the main session's reading): 102 of 111 exports identical, 9 move (the six samples, the held-out house, the held-out 2026 and 2027 models); MCP 0 differ on 629 lines; rule findings `rac_advanced` 2 and `rst_basic` 14 each (the fixed-reference sweep, #1432); body sources base, head, 2024 save: `rac_advanced` beam axis 0, 29, 29, beams along 0, 8, 8, landings 0, 5, 5, runs 0, 10, 5, record boxes 5,205, 5,153, 5,157; `rst_basic` 0, 345, 345 and 0, 9, 9, run 0, 1, 1, record boxes 428, 73, 73; `rac_basic` runs 0, 2, 1, landing slab 0, 0, 1, record boxes 330, 328, 328. The slab and ceiling body source counts do not move on `rac_advanced` and equal the 2024 save's: a count match, not per element. --- ## Maintainer changes, round three (2026-11-05): the check's first results **Run 42010304828** (head e56d31b, filtered; the head side's check turned it red). Held to the same project's 2024 save (beams, landings, sketch outlines) and 2025 save (stair runs), every compared body equal in every field: - `rst_basic` 2026 and 2027, PASS: 354 `IfcBeam`, 1 stair run, 5 `IfcSlab` outlines. - `rac_basic` 2026 and 2027, PASS: 2 stair runs, 12 outlines (2 `IfcCovering`, 10 `IfcSlab`). Left as boxes where the 2024 save draws them: 1 `IfcSlab` (a landing slab) and 1 `IfcRoof`. - `rac_advanced` 2026 and 2027, FAIL, one failure each: ceiling 147534 was required as a compared outline and was not compared. Everything else was equal: 42 beams and landings (37 `IfcBeam`, 5 `IfcSlab`), 10 stair runs, 82 outlines (64 `IfcCovering`, 1 `IfcRoof`, 17 `IfcSlab`), floor 139803 among them. Left as boxes: 4 `IfcRoof`. - On the base side (`main`) the check fails as it should: 42 beams and landings and 10 runs left as boxes, floor 139803 differs in volume (440.512245 m3 against the 2024 save's 441.111228), and 147534 is drawn as an outline where the 2024 save draws its record box. **The ceiling 147534** is a record box in the 2024 save. At base the 2026 save drew an outline. On the head it is neither compared as an outline nor left out, so the Sketch curve list now holds it to the record box as 2024 does (inferred from the counts). The check now compares it under whatever source each save gives it and prints class, `BodySource`, `ProfileResolved` and volume in every save, so the next run states it. Nothing was removed from the required list or allowlisted. **The held-out house's roof** is back in the box list: its export is byte for byte `main`'s in that run. **rac_advanced's one compared `IfcRoof` and 4 left as boxes** are the same on both sides, so roofs are on `main`'s reader. **Head fec4833** is e56d31b plus the named-element check, these counts in the docs, a signed merge of `main` (with #1432 and #1431) and a signed merge of puzzbobb's own merge of `main`. **Final unfiltered Measure run 42016210686** (`base=main`, nordic, R2025, held-out, samples) is on it, dispatched from `fix/1426-bodies-across-saves` (the same head): it should read `rules:` findings 0 on the 2026 and 2027 samples now that #1432 is in. Not read yet; the docs carry run 42010304828's counts. --- ## Maintainer changes, round four (2026-11-05): the second read **Run 42016210686** (head fec4833, unfiltered; the main session's reading and mine of its artifacts): 103 of 111 exports identical, 8 move (the six 2026 and 2027 samples and the held-out 2026 and 2027 models); the EXPRESS `rules:` findings are 0 on 90 models and on 18 held-out ones (#1432 cleared them); MCP 0 differ on 629 lines; the check reads PASS on all six samples. Ceiling 147534: 2024 record box 5.14728698 m3, 2026 record box 5.14728698 m3, 2025 outline 4.15431293 m3. The semantic merge check reads NOT MEASURED on this commit because a fork's pull request is never scored there, which is by design. **Head d3635bb** (final unfiltered Measure: run 42023546789, not read yet): - **Only tread landings are drawn on 2026 and 2027.** A monolithic landing's outline lines go through `scan_landing_lines` and `scan_run_data`, which read 2024 only, so it stays its box: `rac_advanced`'s 5 landings are `native_landing_tread`, `rac_basic`'s one landing slab is a box. The matrix name, `user_impact` and notes, README, status, evidence, compatibility, supported-profile, the changelog fragment and RE-341 say so. - **The check is a job of its own** (`bodies-across-saves`, reading the head results), so a failure turns the run red and Compare still reports. A sample without its 2024 or 2025 save is SKIPPED, one with only some PARTIAL, and neither is a pass: each prints a notice and a line in the run summary, as does a run without `samples=true`, a `scorers` input that excludes it, or `sample_years` with no 2026 or 2027 sample. `sample_years="2026 2027"` no longer fails falsely. An unknown project fails. `docs/maintaining.md` says a change to a reader of Revit 2024 to 2027 is measured with `samples=true`. - **Outlines are compared with both earlier saves** (the 2025 one without scoring), and floor 139803 is printed in every save with its volume and vertex count. **Resolved in round five:** the floor is 441.111228 m3 with 170 vertices on the 2024, 2026 and 2027 saves and 440.512245 m3 with 24 on the 2025 save, which draws its arcs as chords because the arc readers (RE-96, RE-100) are not enabled on 2025; the 2024 reading is the one measured against Revit. It stays an outline. Enabling the arc readers on 2025 is #1440. - **Public docs say a sloped roof on 2026 and 2027 can still be a level block** (the record-box solve, as on `main`), that the check compares bodies and not quantities or property sets, that it cannot catch an error the earlier save shares, and that no 2026 or 2027 held-out model holds an `IfcBeam`, so the beam reader has run only on two Autodesk samples saved from earlier releases. - The fragment and report are renamed `...-beams-stairs-sketches`. --- ## Maintainer changes, round five (2026-11-05): #1428 merged, and the floor **Run 42023546789** (head d3635bb, unfiltered; the main session's reading): 103 of 111 exports identical, 8 move (the six 2026 and 2027 samples and two held-out models), `rules:` findings 0 on 90 models and 18 held-out, all six checks PASS, Compare green. **The floor is resolved, not open:** floor 139803 has 170 vertices and 441.111228 m3 on the 2024, 2026 and 2027 saves and 24 vertices and 440.512245 m3 on the 2025 save, so the 2025 save draws its arcs as chords (the arc readers RE-96 and RE-100 are not enabled there) and the 2024 reading is the one measured against Revit. Sketch outlines against the 2025 save: 81 equal, 1 differs (this floor), 0 drawn otherwise. Ceiling 147534 is a record box on 2024, 2026 and 2027 (5.147 m3) and an outline on 2025 (4.154 m3), because 2025 has no Sketch curve list reader. #1440 is the 2025 arc readers. **Head c8fb8d1** is d3635bb plus a signed merge of `main` (8f1c136, #1428 and #1432 and #1431 among it) and one commit. Two conflicts, both resolved by keeping both: `tools/ci/measure-reference-models.sh` (my bodies check and #1428's `areas_across_saves` side by side; the Areas call runs right after the exports and before any sample's IFC is deleted, so the saves my check keeps change nothing for it) and `docs/format-reconnaissance.md` (the RE-333 and RE-341 addenda). **A red Areas gate skipped Compare.** #1428's gate was a step of the measure job, so a failure there removed Compare's report, as my first bodies check did before round four. Both gates are now steps of one job, `same-project-gates` (`tools/ci/check-bodies-across-saves.sh` and `tools/ci/check-areas-across-saves.sh`, the Areas step moved with its logic unchanged: an `exit 0` and the scorer's own `passed: 25 Areas, 25 with a body, on each of 4 saves` line), each running whatever the other did, reading the head shards one directory each (two shards write an `areas_across_saves.txt`). Compare does not need that job, so a red gate leaves its report. Each gate keeps its own notice on a skip, and the job still needs `samples=true`. Tested with fake results: pass, skipped shard beside a passed one, fail, no result, no samples. **Final unfiltered Measure: run 42027058162** on c8fb8d1 (`base=main`, nordic, R2025, held-out, samples), the first run with both gates and the merged `rac_advanced` Areas. Expected: the same 8 exports against the new `main`, all six bodies checks PASS, the Areas gate passing. Not read yet; the docs carry run 42023546789's counts, labelled as that head. --- **Final unfiltered Measure on the merged head, run 42027058162 (c8fb8d1), read by the maintainer:** 103 of 111 exports are identical to main; 8 move, the six 2026 and 2027 samples of `rac_advanced`, `rac_basic` and `rst_basic` and 2 held-out models. `rules:` findings 0 on 90 models and 18 held-out, MCP 0 differ on 629 lines. The new `Same-project gates` job passes: all six bodies checks read PASS and the Areas gate passes with 25 Areas and 25 bodies on each of 4 saves. Compare is green. The semantic check reads NOT MEASURED because a fork's pull request is never scored, by design. Refs #1190, #421 --------- Co-authored-by: Griffin Long <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A click in the viewer now picks what is drawn. A raycast does not look at
visible, so with a category hidden, a click on what is drawn behind it selected the hidden element.viewer/tests/folded-pieces.spec.tsis the first browser test of a piece folded into another element's body: on the BIM4LCA office as built it hides every category but the folded pieces' one, and clicks until a click lands on a folded piece, read from the raycast's own hit. The panel's ElementId, Name and GlobalId and the selected tree row are the owner's, the panel has no Extents group, the IfcCovering category count is the 111 the tree lists rather than the 158 meshes drawn, and the schedule total is the elements the export writes.Motivation
#1422 and #1423 changed how a click on a folded piece resolves, and no browser test could reach it: none of the models the browser tests hold has a folded piece. The probe of #1423 proves the Rust side only. Writing this test turned up the pick bug, which applies to every model.
Changes
viewer/src/main.ts:pickEntitytakes the first hit that is drawn (isDrawn, which walks the parents). A category hidden before the meshes arrived now stays hidden: the toggle only ever reached the meshes the scene already had (applyCategoryVisibilityonce the model is in).viewer/tests/folded-pieces.spec.ts: the test. It records the worker's model and scene and the raycast's hits, and every click is a real pointer event. It needsRVT_VIEWER_OFFICEand is skipped without it. While it scans for a click on a piece it holds back the worker's panel requests, because each one queues a whole-model decode (a first version took 11.9 minutes in CI); that is the one thing it changes in the page, it is released before the click that is asserted, and that click is made again at the same point with a hidden element in front of what it selects. It checks the panel, the GlobalId against the model, the tree row, that no size is stated, the category and schedule counts of the written elements, and that a stair flight shows its stair's storey..github/workflows/viewer-test.yml: browser tests 1/3 and Deploy viewer's leg (so the release wasm too) run it, on a copy of the office as built restored from the cache or fetched by byte range, checked against the pin inresearch/bim4lca-measure.tsv. Onlymainsaves that cache, and only a file that was verified. An unreachable host, or a fetch over 240 s, reports NOT MEASURED and skips the test; a file that no longer matches its pin fails.Testing
Unit tests are banned; this is end to end.
mainat a4044dc, system Chrome, headless), run locally against the pinned file: pass in 58.7 s. Click 373 of the scan landed on folded piece 13807 of ceiling 2105195, and the panel was the ceiling's; 19 owners, 47 folded pieces, IfcCovering 111 listed. That build does not have the pick fix, so that run dropped hidden hits inside its own capture to reach the piece, and says nothing about the fix. It also predates the schedule total check.office: 19 owners, 47 folded pieces, 12974 written; IFCCOVERING 111 listed; ... 13 clicks had a hidden element, 11.9 minutes). On the final head ef66150 it passes in 4.4 minutes, inside a leg of about 7:office: 19 owners, 47 folded pieces, 12974 written; IFCCOVERING 111 listed; click 2 hit piece 13762 of 2103288, 2 clicks had a hidden element in front. Browser tests 1/3 reads 10 passed, 6 skipped. That includes the stair flight's storey and the re-click with a hidden element in front.Not exercised: a body piece with a solid or saved mesh that stays its own element (
writtenElementOffor a listed piece). No model the test opens has one reachable this way, so that path is checked by reading only.Audit-honesty checklist
changelog.d/fixed/.Legal and contribution hygiene
Breaking changes
None.
Related issues
Closes #1422: the panels (#1423),
docs/viewer-api.md, and now the office in a real browser; Einhoven's Playwright pins are checked by this PR's CI.