cultcache-ts: a load and an index registration name the least violation of the resulting state #103

Merged
libby merged 6 commits from hands/variants-pair-order-ts into main 2026-11-11 12:00:00 +00:00
Member

TS side of variants:cut_spec:cut-pair-order-ts.r1. A load and an index registration name the least violation of the state they would leave (RULE: variants❓unique-index-refusal-pair-rule, option least-pair), by UTF-16 code unit.

  • One whole-state judge refuseLeastIndexSharing in cult-cache.ts, used by pullAllBackingStores (once, over the would-be state, before the swap) and #deriveTypeLookups (registerIndex / registerNameLookup). The per-record judge no longer runs on the load path; a single put keeps it (#writeNow). The first-group throw in #deriveTypeLookups is gone.
  • Test vectors refusals.msgpack: every row TS can perform walks the 18 rows TS can perform (5, 8-13, 19-22, 24, 25, 27, 29, 31-33; no batch commit) and asserts 18. Two superseded tests deleted (text-informational verdict parity; key order carried by row 5).
  • Merged with origin/main (vector rows 1-33); the PR diff is the TS runtime only. Holder, group, value and key identity are ordinal.

Verification: unique-index.test.js 21/21; whole package 202 pass, 4 skipped, 1 fail (browser-entry: esbuild reads an empty /var/lib/mind-libby-self/package.json up-tree, a Self-seat artifact unrelated to this diff). Row 8 fails at origin/main. Hand mutants (localeCompare keys/alias, code-point keys, first-found, greatest, alias ignored, case-insensitive holders, unsorted keys): 8/8 killed.

Round 2: 12 hand mutants (case-insensitive holders, group without type, value lowercase/trim/NFC/NFKC, holder NFC, key sort NFD, alias order desc/case-fold/code-point, case-insensitive held-key exclusion): 10 killed by named rows; 2 survive (key sort by NFD; alias order by code point), both equivalent on the vector's data.

🤖 Generated with Claude Code

TS side of variants:cut_spec:cut-pair-order-ts.r1. A load and an index registration name the least violation of the state they would leave (RULE: variants:question:unique-index-refusal-pair-rule, option least-pair), by UTF-16 code unit. - One whole-state judge `refuseLeastIndexSharing` in cult-cache.ts, used by `pullAllBackingStores` (once, over the would-be state, before the swap) and `#deriveTypeLookups` (registerIndex / registerNameLookup). The per-record judge no longer runs on the load path; a single put keeps it (`#writeNow`). The first-group throw in `#deriveTypeLookups` is gone. - Test `vectors refusals.msgpack: every row TS can perform` walks the 18 rows TS can perform (5, 8-13, 19-22, 24, 25, 27, 29, 31-33; no batch commit) and asserts 18. Two superseded tests deleted (text-informational verdict parity; key order carried by row 5). - Merged with origin/main (vector rows 1-33); the PR diff is the TS runtime only. Holder, group, value and key identity are ordinal. Verification: unique-index.test.js 21/21; whole package 202 pass, 4 skipped, 1 fail (browser-entry: esbuild reads an empty /var/lib/mind-libby-self/package.json up-tree, a Self-seat artifact unrelated to this diff). Row 8 fails at origin/main. Hand mutants (localeCompare keys/alias, code-point keys, first-found, greatest, alias ignored, case-insensitive holders, unsorted keys): 8/8 killed. Round 2: 12 hand mutants (case-insensitive holders, group without type, value lowercase/trim/NFC/NFKC, holder NFC, key sort NFD, alias order desc/case-fold/code-point, case-insensitive held-key exclusion): 10 killed by named rows; 2 survive (key sort by NFD; alias order by code point), both equivalent on the vector's data. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Unique-index vectors: pin holder identity by case (rows 23-24)
Some checks failed
CultMesh QUIC native / Build win32-x64 (pull_request) Has been skipped
CultMesh QUIC native / Build linux-x64 (pull_request) Has been skipped
CultMesh QUIC native / Release native binaries (pull_request) Has been skipped
CultMesh portability and performance / ubuntu-latest reactive semantics and leases (pull_request) Has been cancelled
CultMesh QUIC native / Verify committed binaries match SHA256SUMS (pull_request) Has been cancelled
d02b56a692
Two holders of one value whose keys differ only by case are two holders; a case-folding dedupe would see one and miss the refusal.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
cultcache-ts tests: walk refusals row 24 (holders by case); 12 rows
Some checks failed
CultMesh QUIC native / Build win32-x64 (pull_request) Has been skipped
CultMesh QUIC native / Build linux-x64 (pull_request) Has been skipped
CultMesh QUIC native / Release native binaries (pull_request) Has been skipped
CultMesh QUIC native / Verify committed binaries match SHA256SUMS (pull_request) Has been cancelled
CultMesh portability and performance / ubuntu-latest reactive semantics and leases (pull_request) Has been cancelled
75fabfeb50
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
cultcache-ts tests: walk the 18 rows TS can perform of refusals.msgpack rows 1-33
Some checks failed
CultMesh QUIC native / Build win32-x64 (pull_request) Has been skipped
CultMesh QUIC native / Build linux-x64 (pull_request) Has been skipped
CultMesh QUIC native / Release native binaries (pull_request) Has been skipped
CultMesh QUIC native / Verify committed binaries match SHA256SUMS (pull_request) Has been cancelled
CultMesh portability and performance / ubuntu-latest reactive semantics and leases (pull_request) Has been cancelled
812143b498
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
libby merged commit 1211e8c6dc into main 2026-11-11 12:00:00 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
GameCult/CultLib!103
No description provided.