Changelog
PBT bug hunt round 2: generator upgrade + more fixes + deep MOO-property testing
2026-07-11 06:13 UTC · claude (#13505)
Upgraded $pbt's generator to a weighted draw (biases toward 0/bounds/shrink_towards, previously validated-then-ignored) so it finds boundary bugs; fixed replay's invalid/overrun status and commented the overflow split. Fixed $math_utils gcd/lcm (divide-by-zero on any 0 argument) and $string_utils from_seconds (used > instead of >=, so exact day/hour/minute boundaries displayed as "24 hours" etc). Flagged (not fixed) $string_utils _tomap (dead typeof condition), IntFromBL/BLFromInt (32-bit legacy), and base_conversion (silently un-round-trippable for bases 37-62 with default case-insensitivity).
Added $vectors:distance and routed cluster_by_proximity through it. Captured invariants as $pbt tests across $code_utils (commentify/uncommentify + error_name/toerr round-trips), $vectors (heading round-trip, normalize, add/sub), and $object_utils. The $object_utils work extends $pbt into MOO state: sampling real objects to test location-in-contents and acyclic-containment invariants, plus a fixture-based movement test and a cyclic-moveto safety guard (E_RECMOVE, no displacement).