From 09d48fba5ae7c132f4cc0b6a9900facff25020c9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 12 Aug 2026 12:32:18 +0000 Subject: [PATCH] Version Packages --- .changeset/fix-open-ceiling.md | 26 -------------------------- CHANGELOG.md | 27 +++++++++++++++++++++++++++ package.json | 2 +- 3 files changed, 28 insertions(+), 27 deletions(-) delete mode 100644 .changeset/fix-open-ceiling.md diff --git a/.changeset/fix-open-ceiling.md b/.changeset/fix-open-ceiling.md deleted file mode 100644 index 7e11ba0..0000000 --- a/.changeset/fix-open-ceiling.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -"@theyoungwolf/lexorank": patch ---- - -Fix `rankBetween` producing a rank outside its bounds when the two majors are -adjacent and the upper bound carries a minor. - -`minorSpaceRanks` only substituted an absolute ceiling when `high.minor` was -exactly `":"`. Otherwise it compared the lower bound's fraction against a -fraction belonging to a _different_ major, which can run descending and yields a -value below `prev`. `assertWithinBounds` caught it, so the symptom was a -`RankInvariantError` rather than silent corruption, but the call still failed. - -The shape is reachable from ranks this library produced: grow a fraction at the -top of one major and another at the bottom of the next, then delete the item -between them. Their neighbours are now the failing pair. - -The minor's ceiling is now treated as open whenever the bounds do not share a -major, when the upper bound is absent, or when a bucket boundary was spoofed — -and the low-side pivot marks it open too, since borrowing the lower bound's -character puts every extension below the original ceiling. - -Ranks already written are unaffected: 40,000 random insertions driven entirely -by library calls produce byte-identical output to the previous release, as do -`rebalance`, `rankAfter` and `rankBefore`. Only inputs that previously threw -change. diff --git a/CHANGELOG.md b/CHANGELOG.md index 4bd3e59..70f256e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,32 @@ # @theyoungwolf/lexorank +## 0.1.3 + +### Patch Changes + +- 649fc48: Fix `rankBetween` producing a rank outside its bounds when the two majors are + adjacent and the upper bound carries a minor. + + `minorSpaceRanks` only substituted an absolute ceiling when `high.minor` was + exactly `":"`. Otherwise it compared the lower bound's fraction against a + fraction belonging to a _different_ major, which can run descending and yields a + value below `prev`. `assertWithinBounds` caught it, so the symptom was a + `RankInvariantError` rather than silent corruption, but the call still failed. + + The shape is reachable from ranks this library produced: grow a fraction at the + top of one major and another at the bottom of the next, then delete the item + between them. Their neighbours are now the failing pair. + + The minor's ceiling is now treated as open whenever the bounds do not share a + major, when the upper bound is absent, or when a bucket boundary was spoofed — + and the low-side pivot marks it open too, since borrowing the lower bound's + character puts every extension below the original ceiling. + + Ranks already written are unaffected: 40,000 random insertions driven entirely + by library calls produce byte-identical output to the previous release, as do + `rebalance`, `rankAfter` and `rankBefore`. Only inputs that previously threw + change. + ## 0.1.2 ### Patch Changes diff --git a/package.json b/package.json index 0a155ed..ff693f6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@theyoungwolf/lexorank", - "version": "0.1.2", + "version": "0.1.3", "description": "A feature-rich TypeScript implementation of the LexoRank ordered-ranking algorithm: bucket overflow, major/minor fractional precision, and batch insertion.", "keywords": [ "lexorank",