tests: check alternate Markdown link titles (TEST-MARKDOWN-LINK-TITLES) #839

Manually merged
github merged 1 commit from gh-pr/839/head into gh-pr/839/base 2026-11-26 09:23:55 +00:00
Owner

@⁠TheGeogeo on GitHub · 2026-11-24 14:25 UTC · original
TheGeogeo:test/markdown-link-title-delimiters → main · +24 −1 · 1 files · 1 commits · merged 2026-11-25 21:24 UTC

Claimed in the coordination issue as: TEST-MARKDOWN-LINK-TITLES

What and why

The link checker misses broken inline destinations when the title is single-quoted, parenthesized or contains an escaped delimiter. Match the three CommonMark title forms without changing the destination capture. The synthetic regression checks broken files, a missing anchor and an existing anchor. This carries forward my earlier ProjectLeonida/Leonida PR #10084 onto this repository's current matcher.

Tested

After a rebase on main 6293c1c4 (32fc5eec, same patch as 3eee59b8), on Windows 11, Python 3.12.4: tests/test_docs_links.py 17 OK; test_tool_stdout_encoding.py, test_docs_cli_flags.py and test_text_write_line_endings.py OK; git diff --check and the no-game-data check clean.

  • Windows, Python 3.12.4. The regression failed against the d0da7dad matcher because it reported none of three broken destinations.
  • python -I -B tests/test_docs_links.py: 17 passed.
  • python -B -m unittest discover -s tests -p 'test_docs_*.py': 48 passed.
  • git diff --check and python -I -B scripts/check_no_game_data.py tests/test_docs_links.py: passed.

GPUs tested: n/a. CPU-only tests.

AI-assisted: Yes, Codex.

Checklist

  • Based on current main.
  • One topic.
  • No game data, keys, or decryption.
  • Translator contract entry: not applicable.
**@⁠TheGeogeo** on GitHub · 2026-11-24 14:25 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/839) `TheGeogeo:test/markdown-link-title-delimiters` → `main` · +24 −1 · 1 files · 1 commits · merged 2026-11-25 21:24 UTC Claimed in the coordination issue as: [TEST-MARKDOWN-LINK-TITLES](https://git.gtahub.st/github/ubiquitarianism--leonida/issues/14) ### What and why The link checker misses broken inline destinations when the title is single-quoted, parenthesized or contains an escaped delimiter. Match the three [CommonMark title forms](https://spec.commonmark.org/0.31.2/#links) without changing the destination capture. The synthetic regression checks broken files, a missing anchor and an existing anchor. This carries forward my earlier `ProjectLeonida/Leonida` PR #10084 onto this repository's current matcher. ### Tested After a rebase on `main` `6293c1c4` (`32fc5eec`, same patch as `3eee59b8`), on Windows 11, Python 3.12.4: `tests/test_docs_links.py` 17 OK; `test_tool_stdout_encoding.py`, `test_docs_cli_flags.py` and `test_text_write_line_endings.py` OK; `git diff --check` and the no-game-data check clean. - Windows, Python 3.12.4. The regression failed against the `d0da7dad` matcher because it reported none of three broken destinations. - `python -I -B tests/test_docs_links.py`: 17 passed. - `python -B -m unittest discover -s tests -p 'test_docs_*.py'`: 48 passed. - `git diff --check` and `python -I -B scripts/check_no_game_data.py tests/test_docs_links.py`: passed. GPUs tested: n/a. CPU-only tests. AI-assisted: Yes, Codex. ### Checklist - [x] Based on current `main`. - [x] One topic. - [x] No game data, keys, or decryption. - Translator contract entry: not applicable.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:23:52 +00:00
github manually merged commit 32fc5eec48 into gh-pr/839/base 2026-11-26 09:23:55 +00:00
Author
Owner

@⁠abnalstlll-byte on GitHub · 2026-11-24 14:40 UTC · original · approved these changes

Audited and verified. Extends markdown link regex in ests/test_docs_links.py to support all CommonMark title delimiter variants (double quotes, single quotes, and parentheses with escape handling), preventing spurious link target truncation in docs linting. Unit tests pass cleanly. Approved.

**@⁠abnalstlll-byte** on GitHub · 2026-11-24 14:40 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/839#pullrequestreview-6041301045) · **approved these changes** Audited and verified. Extends markdown link regex in ests/test_docs_links.py to support all CommonMark title delimiter variants (double quotes, single quotes, and parentheses with escape handling), preventing spurious link target truncation in docs linting. Unit tests pass cleanly. Approved.
Author
Owner

@⁠TheGeogeo on GitHub · 2026-11-24 21:22 UTC · original

Rebased on main 6293c1c4: 3eee59b8 -> 32fc5eec, same patch (git range-diff). The previous base failed tests/test_tool_stdout_encoding.py, which #948 fixed on main, and the earlier CI run never started (action_required).

  • Windows 11, Python 3.12.4, after the rebase: tests/test_docs_links.py 17 OK; test_tool_stdout_encoding.py, test_docs_cli_flags.py and test_text_write_line_endings.py OK; git diff --check and the no-game-data check clean.
  • The approval here was made before the rebase, on 3eee59b8.

No code change in this rebase. CI on the new head is still queued.

AI-assisted: yes (Claude Code).

**@⁠TheGeogeo** on GitHub · 2026-11-24 21:22 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/839#issuecomment-7144841149) Rebased on `main` `6293c1c4`: `3eee59b8` -> `32fc5eec`, same patch (`git range-diff`). The previous base failed `tests/test_tool_stdout_encoding.py`, which #948 fixed on `main`, and the earlier CI run never started (action_required). - Windows 11, Python 3.12.4, after the rebase: `tests/test_docs_links.py` 17 OK; `test_tool_stdout_encoding.py`, `test_docs_cli_flags.py` and `test_text_write_line_endings.py` OK; `git diff --check` and the no-game-data check clean. - The approval here was made before the rebase, on `3eee59b8`. No code change in this rebase. CI on the new head is still queued. AI-assisted: yes (Claude Code).
This discussion has been locked. Commenting is limited to contributors.
No description provided.