ci: also reject the Arabic letter mark U+061C #345

Manually merged
github merged 1 commit from gh-pr/345/head into gh-pr/345/base 2026-11-26 21:44:41 +00:00
Owner

@⁠thepatrickworld on GitHub · 2026-11-21 22:49 UTC · original
thepatrickworld:patch-1 → main · +13 −8 · 1 files · 1 commits · merged 2026-11-21 22:58 UTC

Problem

tests/bidi_controls_check.py covers the embeddings and overrides U+202A..U+202E and the isolates U+2066..U+2069, but not U+061C (ARABIC LETTER MARK), which #254 lists alongside them and which reorders displayed text the same way.

A tracked source file carrying only U+061C passes the check today. Reproduced on main at 8069de2:

$ printf 'x = 1  # \u061c hidden\n' > probe_alm.py && git add probe_alm.py
$ python3 tests/bidi_controls_check.py
Self-test passed.
Checked 281 tracked source, script and build/CI files: no bidirectional controls.
$ echo $?
0

Change

  • add 0x061C to CONTROLS
  • add a self-test fixture carrying the code point, with its expected diagnostic
  • widen the assertion on the covered set
CONTROLS = frozenset([0x061C, *range(0x202A, 0x202F), *range(0x2066, 0x206A)])

Verification

On main at 8069de2 with this change applied:

$ python3 tests/bidi_controls_check.py
Self-test passed.
probe_alm.py:1: U+061C ARABIC LETTER MARK
$ echo $?
1

--self-test passes before and after the change. Nothing else is touched: same tracked file set, same suffixes, same diagnostic format.

Refs #254

AI-assisted

**@⁠thepatrickworld** on GitHub · 2026-11-21 22:49 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/345) `thepatrickworld:patch-1` → `main` · +13 −8 · 1 files · 1 commits · merged 2026-11-21 22:58 UTC ## Problem `tests/bidi_controls_check.py` covers the embeddings and overrides `U+202A..U+202E` and the isolates `U+2066..U+2069`, but not `U+061C` (ARABIC LETTER MARK), which #254 lists alongside them and which reorders displayed text the same way. A tracked source file carrying only `U+061C` passes the check today. Reproduced on `main` at `8069de2`: ```text $ printf 'x = 1 # \u061c hidden\n' > probe_alm.py && git add probe_alm.py $ python3 tests/bidi_controls_check.py Self-test passed. Checked 281 tracked source, script and build/CI files: no bidirectional controls. $ echo $? 0 ``` ## Change - add `0x061C` to `CONTROLS` - add a self-test fixture carrying the code point, with its expected diagnostic - widen the assertion on the covered set ```python CONTROLS = frozenset([0x061C, *range(0x202A, 0x202F), *range(0x2066, 0x206A)]) ``` ## Verification On `main` at `8069de2` with this change applied: ```text $ python3 tests/bidi_controls_check.py Self-test passed. probe_alm.py:1: U+061C ARABIC LETTER MARK $ echo $? 1 ``` `--self-test` passes before and after the change. Nothing else is touched: same tracked file set, same suffixes, same diagnostic format. Refs #254 _AI-assisted_
Add U+061C to the covered controls, with a self-test fixture and a widened
assertion on the covered set. Refs #254.
AI-assisted
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 21:44:39 +00:00
github manually merged commit e4f504fb2b into gh-pr/345/base 2026-11-26 21:44:41 +00:00
Author
Owner

@⁠R0Y00 on GitHub · 2026-11-21 22:57 UTC · original

Approved scope. U+061C is a directional mark. This head adds it by name to the existing tracked-file scan, and the regression checks tools/mark.py:1: U+061C ARABIC LETTER MARK. The explicit code-point set also leaves visible ASCII escapes and ordinary Arabic text valid.

**@⁠R0Y00** on GitHub · 2026-11-21 22:57 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/345#issuecomment-7070547781) Approved scope. U+061C is a directional mark. This head adds it by name to the existing tracked-file scan, and the regression checks `tools/mark.py:1: U+061C ARABIC LETTER MARK`. The explicit code-point set also leaves visible ASCII escapes and ordinary Arabic text valid.
This discussion has been locked. Commenting is limited to contributors.
No description provided.