merge_check: preserve Unicode line separators in squash subjects (OLD-10032) #893

Merged
TanmaySatyam merged 1 commit from upstream-pr/893 into main 2026-11-24 16:11:23 +00:00
TanmaySatyam commented 2026-11-24 15:00:53 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by TanmaySatyam on 2026-11-24T15:00:53Z.


Claimed in the coordination issue as: OLD-10032

Summary

Carries forward old-pr/10032 (carried-over draft #300) cleanly onto current main (3d3770c16), preserving the original author's (maxence468) commit (52742602f, 7 insertions, 1 deletion):

  • Changes out.splitlines() to out.split("\n") in scripts/merge_check.py:prior_merges() so Unicode line separators (such as U+2028) inside a squash-merge subject do not split a single git log entry into two lines and misattribute a PR number. Matches the split("\n") convention already used elsewhere in scripts/merge_check.py.
  • Adds test_unicode_line_separator_in_squash_subject in tests/test_merge_check.py.

Testing & Verification

  • AI-assisted: yes (rebase and verification).
  • Synthetic fixtures only: no game data used (python -I scripts/check_no_game_data.py scripts/merge_check.py tests/test_merge_check.py exits 0).
  • Host: Windows 11, Python 3 (stdlib-only; no runtime/GPU code touched).
  • Tests:
    • python -I tests/test_merge_check.py -v: 24/24 OK (including test_unicode_line_separator_in_squash_subject)
    • python -I tests/test_text_write_line_endings.py: 3/3 OK
    • python -m compileall -q scripts/merge_check.py tests/test_merge_check.py: OK
<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5474662996 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/893). Originally posted by [TanmaySatyam](https://github.com/TanmaySatyam) on 2026-11-24T15:00:53Z. --- Claimed in the coordination issue as: OLD-10032 ### Summary Carries forward `old-pr/10032` (carried-over draft #300) cleanly onto current `main` (`3d3770c16`), preserving the original author's (`maxence468`) commit (`52742602f`, 7 insertions, 1 deletion): - Changes `out.splitlines()` to `out.split("\n")` in `scripts/merge_check.py:prior_merges()` so Unicode line separators (such as `U+2028`) inside a squash-merge subject do not split a single `git log` entry into two lines and misattribute a PR number. Matches the `split("\n")` convention already used elsewhere in `scripts/merge_check.py`. - Adds `test_unicode_line_separator_in_squash_subject` in `tests/test_merge_check.py`. ### Testing & Verification - **AI-assisted:** yes (rebase and verification). - **Synthetic fixtures only:** no game data used (`python -I scripts/check_no_game_data.py scripts/merge_check.py tests/test_merge_check.py` exits 0). - **Host:** Windows 11, Python 3 (stdlib-only; no runtime/GPU code touched). - **Tests:** - `python -I tests/test_merge_check.py -v`: 24/24 OK (including `test_unicode_line_separator_in_squash_subject`) - `python -I tests/test_text_write_line_endings.py`: 3/3 OK - `python -m compileall -q scripts/merge_check.py tests/test_merge_check.py`: OK
LewisStephens99 commented 2026-11-24 15:09:37 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by LewisStephens99 on 2026-11-24T15:09:37Z.


Independent verification on Windows 11, Python 3.14:n- python -I tests/test_merge_check.py: 24/24 passed.n- No game data or GPU used. AI-assisted.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7135556218 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/893#issuecomment-7135556218). Originally posted by [LewisStephens99](https://github.com/LewisStephens99) on 2026-11-24T15:09:37Z. --- Independent verification on Windows 11, Python 3.14:`n- `python -I tests/test_merge_check.py`: 24/24 passed.`n- No game data or GPU used. AI-assisted.
Sign in to join this conversation.
No reviewers
No labels
No milestone
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.

Reference
ProjectLeonida/mandy!893
No description provided.