Files
OpenFrontIO/tests
Evan Pelle e4f4b4d310 fix: stop name censor flagging innocent words like "cons"
The collapse matcher (which catches elongation bypasses like "niiigger")
pre-collapses banned words by reducing every run of a repeated letter to
one. That turns short slurs with a natural double letter into common
substrings — "coons" -> "cons", "boong" -> "bong", "bussy" -> "busy",
"nigger" -> "niger" — and since it substring-matches, those censor
innocent names like console, icons, busy, Bongo, Nigeria, and negative.
Against the live banned list this falsely censored ~half of ordinary
test names.

A collapse hit is only a genuine elongation bypass when the matched text
actually repeats a letter. Filter collapse matches to keep only those
whose span (widened one char each side, to catch a trailing collapsed
duplicate such as "nigg" -> "nig") contains a repeated letter. This can
only remove collapse matches, never add them: a canonically-spelled slur
with no repeat equals its deduped pattern and is still caught by the
literal substring matcher, so no real slur is lost.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-27 16:57:56 +00:00
..
2026-06-24 15:15:05 -07:00
2026-05-22 13:19:22 +01:00
2026-06-19 14:54:09 -07:00
2026-03-17 15:55:47 -07:00