Skip to content

onlyworlds 0.45.1

Choose a tag to compare

@github-actions github-actions released this 24 Oct 11:55
· 23 commits to main since this release
  • The .owworld reader's NFC is Unicode 15.1's own, built from the set's files. OW-18 folds every entry name with NFC, then simple case folding, and two names that fold to one refuse the file. The fold was already a table from the vendored CaseFolding-15.1.0.txt; the NFC before it was the interpreter's unicodedata.normalize, which is Python's Unicode (15.0 on 3.12, 16.0 on 3.14). Since schema-dist serial 57 the spec (§4.7) rules that the NFC is built from UnicodeData-15.1.0.txt and CompositionExclusions-15.1.0.txt, vendored beside CaseFolding, never a runtime's. On 3.14 the old reader joined 20 code points that 15.1 leaves unassigned (Todhri, Tulu-Tigalari, Gurung Khema, Kirat Rai): U+11383 against U+11382 U+113C9 was refused as one name, and is two at 15.1. The same fold matches a private producer's RECORDS.json entry to its directory (OW-8), so that follows too.
  • onlyworlds.worldfile.nfc, UAX #15 from the two files: full canonical decomposition (Hangul by arithmetic), canonical ordering, canonical composition skipping the listed exclusions, singletons and non-starter decompositions. Its tables are _nfc.py, generated by codegen/generate_nfc.py as _casefold.py is by generate_casefold.py, so the wheel needs no file from codegen/. worldfile.py no longer imports unicodedata.
  • Tests: every line of Unicode's NormalizationTest-15.1.0.txt (19,074 lines, vendored under tests/fixtures/, 2.6 MB, its sha256 checked) holds both NFC invariants, and every code point Part 1 does not list is its own NFC; the 20 code points stay apart in a world file (and are checked joined under unicodedata 16.0 or later, so the test is live); the generated module is current; the .owworld set holds at 93 of 93. Mutants, each restored: composing an exclusion, skipping canonical ordering, ordering by code point, dropping Hangul composition, removing blocking, and one-level decomposition each fail the NormalizationTest test; skipping ordering and ordering by code point also fail the set (fail-OW-18-nfc-reorder, pass-OW-18-nfc-same-class); the old unicodedata call fails the 20-code-point test.