Skip to content

Commit 329bf8c

Browse files
authored
fix(changesets): correct twelve semver bumps that would have shipped breaking changes as patch (#3175)
The release was one command from publishing. A changeset decides the version BUMP as well as the changelog text, and nobody had reviewed the changesets -- CodeRabbit was rate-limited across the batch and both review passes were aimed at code and tests. Twelve frontmatter corrections. Each was derived from what the referenced commit actually did to the public surface, not from the changeset's own prose, and the level follows AGENTS.md:68 ("major (>=1.0 pkg) or minor (0.x), never patch when the surface shrank") rather than generic semver: bcf-validate-against-official-xsds bcf patch -> major writeBCF throws where it returned a Blob. Probed both sides: at e19aa0e^ "wrote blob, size = 1662"; on main "THREW -> BCF 3.0 requires a positive Camera/AspectRatio". No camera factory in the package sets that field, so the package's own documented createBCFFromIDSReport -> writeBCF path fails. recommended-scale-units drawing-2d + sdk minor -> major getRecommendedScale throws for 0/negative/NaN/Infinity where it returned 1:1000, and the SDK forwards with no catch. export-step-fails-closed-on-... wasm patch -> major export_step_json went String -> Result<String, String> on a root-level pub use. The Rust crate version derives from the highest npm workspace version, so patch would publish ifc-lite-export 5.0.1 with a hard compile break inside ^5.0.0. Precedent: #2766 took major for this shape. ifcx-writer-discards-globalid ifcx patch -> major ids-summarize-not-applicable sdk patch -> minor, + cli patch New required property on a RETURNED type. Minor, not major: nothing in the SDK accepts an IDSValidationSummary, so consumers never construct one. branch-merge-layer-overlay collab patch -> minor collab-snapshot-invented-provenance collab + ifcx patch -> minor symbolic-cycle-truncation-reason server-client patch -> minor symbolic-output-cap + wasm minor csv-numeric-cells-export-as-numbers + wasm major csv-cell-escaper-unification + viewer patch sun-shadows-depth-prepass + viewer minor Effect: packages receiving a major bump go from four to eight. bcf, ifcx, sdk and wasm would each have shipped a breaking change as patch or minor. A fourth body correction, found by review of this commit rather than of the batch: changing recommended-scale-units to major left its own body still arguing "this is minor rather than patch". Correcting a bump without correcting the sentence that justifies it reproduces the exact defect this commit exists to fix. Rationale rewritten to state the narrowed input domain as the reason. Swept the other eleven for the same contradiction; none. Three body corrections, where the text ships AS the changelog: wasm-step-export-non-ascii-x2-directive said encode_ifc_string "was never wired into this writer; it now is". It is still not called: the function is defined at rust/core/src/step_encoding.rs:146 and its only appearance outside rust/core is a comment. The encoding was reimplemented inline. bounded-glb-rep-instancing announced export_step_to_writer under a wasm heading. It is exported from the Rust crate and appears nowhere in rust/wasm-bindings, so npm consumers cannot reach it. Qualified. wasm-bound-symbolic-item-walk-cycle said "none of the three bounds reports anything". That was true when written; a later change in this same release gives them a truncation reason, so the shipped changelog would have contradicted itself. The stale sentence is DELETED rather than annotated: a first attempt added a cross-reference to the superseding changeset, but changesets never render the changeset filename, so it pointed at something no reader can find -- and the two entries land in different CHANGELOG sections (patch vs minor) anyway. The superseding entry states the current behaviour positively, so nothing is lost. NOT changed, after two reviewers disagreed and the evidence settled it: placement-memo-truncation, geometry-bound-layer-slicing-identity-chase and validate-export-formats-externally were flagged for naming an npm package against a Rust-only commit. That is the documented house convention, stated in 74a55a9: "Attribution follows the split precedent already on main: rust/geometry -> @ifc-lite/geometry". Correct as they stand. csv-numeric-cells-export-as-numbers was flagged as export minor -> major for a flipped default. escapeCsvCell and guardSpreadsheetFormula have never been published: added by #3102, still unreleased, shipping for the first time in this release. npm view @ifc-lite/export version = 2.9.4 and its CHANGELOG has no csv-cell entry. A default cannot break callers of a function no consumer can have called. Minor is right; only the missing wasm entry was real. A fifth body correction: dxf-insunits-survey-units stated the scale error BACKWARDS. It said a survey-foot DXF "came in at roughly 1/3.28 scale", i.e. too small. `unitScale` is a MULTIPLIER (convert.ts:232 `wx = p.x * state.unitScale`) and the unknown-code fallback is `unitScale = 1` (convert.ts:129, warning "drawing units treated as metres"), so coordinate 100 in survey feet became 100.0000 m against a true 30.4801 m -- 3.28x TOO LARGE. Corrected. Two reviewers had independently failed to find that import path and this was recorded as unverified rather than edited on a guess; a third look found it at packages/drawing-2d/src/dxf/convert.ts:48. Recording the gap rather than guessing is what made it findable.
1 parent e513c23 commit 329bf8c

16 files changed

Lines changed: 31 additions & 22 deletions

.changeset/bcf-validate-against-official-xsds.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
"@ifc-lite/bcf": patch
2+
"@ifc-lite/bcf": major
33
---
44

55
Validate real `.bcfzip` output against buildingSMART's published BCF XSDs. That check found eleven schema violations in our output; nine are fixed here and two are reported below as needing a decision this change cannot make.

.changeset/bounded-glb-rep-instancing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,6 @@ Grouping follows `collate_refs` exactly: a rep identity whose occurrences disagr
2020

2121
f32 output only. A quantized shared mesh carries a non-uniform dequant scale that cannot fold into a rotating placement without breaking `Matrix4.decompose`, so quantized output still goes out flat.
2222

23-
Also adds `export_step_to_writer`, which emits each record as it is read instead of returning the whole file as a `String`. On a 1 GB model that removes a gigabyte of output from the peak. It buffers internally, so a caller passing a bare `File` does not pay two syscalls per record.
23+
Also adds `export_step_to_writer` to the `ifc-lite-export` Rust crate (it is not exposed through the wasm bindings, so npm consumers cannot call it), which emits each record as it is read instead of returning the whole file as a `String`. On a 1 GB model that removes a gigabyte of output from the peak. It buffers internally, so a caller passing a bare `File` does not pay two syscalls per record.
2424

2525
Output is byte-identical for models with no shareable shapes.

.changeset/branch-merge-layer-overlay.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
'@ifc-lite/collab': patch
2+
'@ifc-lite/collab': minor
33
---
44

55
Fix `mergeBranch(parent, branch, 'layer')` silently dropping every edit the branch made to an entity that already existed in the parent.

.changeset/collab-snapshot-invented-provenance.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
'@ifc-lite/collab': patch
3-
'@ifc-lite/ifcx': patch
2+
'@ifc-lite/collab': minor
3+
'@ifc-lite/ifcx': minor
44
---
55

66
Stop a collab snapshot round trip from inventing per-entity provenance, and carry the real thing on the wire.

.changeset/csv-cell-escaper-unification.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
"@ifc-lite/sdk": patch
44
"@ifc-lite/cli": patch
55
"@ifc-lite/mcp": patch
6+
"@ifc-lite/viewer": patch
7+
"@ifc-lite/wasm": patch
68
---
79

810
CSV cell escaping now has one implementation per language

.changeset/csv-numeric-cells-export-as-numbers.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
---
22
"@ifc-lite/encoding": minor
33
"@ifc-lite/export": minor
4-
"@ifc-lite/lists": patch
4+
"@ifc-lite/lists": major
55
"@ifc-lite/viewer": patch
6-
"@ifc-lite/sdk": patch
7-
"@ifc-lite/cli": patch
8-
"@ifc-lite/mcp": patch
6+
"@ifc-lite/sdk": major
7+
"@ifc-lite/cli": minor
8+
"@ifc-lite/mcp": minor
9+
"@ifc-lite/wasm": major
910
---
1011

1112
CSV: numeric cells export as numbers. **The formula guard's default changed.**

.changeset/dxf-insunits-survey-units.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44

55
Fix DXF import treating $INSUNITS codes 17-24 (gigametres, astronomical units, light years, parsecs, and US Survey feet/inch/yard/mile) as unknown and falling back to metres.
66

7-
The most consequential of these is 21 (US Survey Feet): a civil/survey DXF authored in that unit previously came in at roughly 1/3.28 scale — a large, visible error — even though the fallback correctly warned about the unknown code. US Survey Feet is now converted using its exact legal definition, 1200/3937 m (≈0.3048006096012192 m), not the international foot (0.3048 m exactly); the ~2 parts-per-million difference between the two is the entire reason US Survey Feet is a distinct $INSUNITS code, so Survey inch/yard/mile are derived from the survey foot rather than from international units.
7+
The most consequential of these is 21 (US Survey Feet): a civil/survey DXF authored in that unit previously came in at roughly 3.28x its true size — a large, visible error — even though the fallback correctly warned about the unknown code. US Survey Feet is now converted using its exact legal definition, 1200/3937 m (≈0.3048006096012192 m), not the international foot (0.3048 m exactly); the ~2 parts-per-million difference between the two is the entire reason US Survey Feet is a distinct $INSUNITS code, so Survey inch/yard/mile are derived from the survey foot rather than from international units.

.changeset/export-step-fails-closed-on-malformed-mutations.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
'@ifc-lite/wasm': patch
2+
'@ifc-lite/wasm': major
33
---
44

55
Fix `exportStep` silently discarding the caller's edits when `mutationsJson`

.changeset/ids-summarize-not-applicable.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
2-
"@ifc-lite/sdk": patch
2+
"@ifc-lite/sdk": minor
3+
"@ifc-lite/cli": patch
34
---
45

56
Fix `bim.ids.summarize()` counting a `not_applicable` specification as passed. A specification whose applicability matches zero entities and whose cardinality does not require a match (no `minOccurs`) is neither a pass nor a fail — `@ifc-lite/ids`'s own `validateIDS` report already treats it that way — but `summarize()` had no `not_applicable` bucket, so its unconditional `else` folded every such specification into `passedSpecifications`. That inflated the spec-level pass rate returned by the CLI's `ids --json` output relative to the CLI's own text-mode output (both should read from the same validation, but text mode reads `report.summary` directly while `--json` goes through `summarize()`).

.changeset/ifcx-writer-discards-globalid.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
"@ifc-lite/ifcx": patch
2+
"@ifc-lite/ifcx": major
33
---
44

55
Fix `IfcxWriter` discarding every entity's IFC GlobalId.

0 commit comments

Comments
 (0)