test(tools): shard conventions comment checks under CTest timeout #5678

Merged
MarcZX10 merged 1 commit from upstream-pr/5678 into main 2026-10-15 12:56:52 +00:00
MarcZX10 commented 2026-10-14 06:04:47 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-14T06:04:47Z.


What

Split the conventions comment checker into six deterministic CTest shards. The runner discovers all unittest cases in the module and assigns sorted test IDs across shards, so new cases and classes are included automatically. A regression check verifies that the shards are nonempty and cover each discovered test exactly once. The existing conventions_function_bodies CTest name is retained for shard zero, and every shard keeps the 30-second timeout. References #5672.

Tested

Linux, GCC 12.2, Python 3.11: configured with BUILD_TESTING=ON and ANYPS5_RELINKER_ONLY=ON; all six CTest shards passed with --parallel 2. Running the complete Python module directly passed all 54 cases in 3.29 seconds. The base revision's 53 cases passed in 3.29 seconds. Windows full-suite timing was not tested here.

Checklist

  • Based on current main; no other open PR implements the same change
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt (no code comments added)
  • Unimplemented paths throw; not applicable to this test-only change
  • No notes, investigation .md files or images added to the repository
  • New third-party code is a submodule built from source (not applicable)
  • Generic behavior, not specific to one title
  • Depends on: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4853691638 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-14T06:04:47Z. --- ### What Split the conventions comment checker into six deterministic CTest shards. The runner discovers all `unittest` cases in the module and assigns sorted test IDs across shards, so new cases and classes are included automatically. A regression check verifies that the shards are nonempty and cover each discovered test exactly once. The existing `conventions_function_bodies` CTest name is retained for shard zero, and every shard keeps the 30-second timeout. References #5672. ### Tested Linux, GCC 12.2, Python 3.11: configured with `BUILD_TESTING=ON` and `ANYPS5_RELINKER_ONLY=ON`; all six CTest shards passed with `--parallel 2`. Running the complete Python module directly passed all 54 cases in 3.29 seconds. The base revision's 53 cases passed in 3.29 seconds. Windows full-suite timing was not tested here. ### Checklist - [x] Based on current `main`; no other open PR implements the same change - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except technical debt (no code comments added) - [x] Unimplemented paths throw; not applicable to this test-only change - [x] No notes, investigation `.md` files or images added to the repository - [x] New third-party code is a submodule built from source (not applicable) - [x] Generic behavior, not specific to one title - [x] Depends on: none - [x] Unblocks: none - [x] GPUs tested: n/a - [x] AI-assisted: yes
ideabsassistenza commented 2026-10-14 08:03:14 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by ideabsassistenza on 2026-10-14T08:03:14Z.


Independent Windows validation of head 326845537d12790bdd031efe94f06d8c37f6c5fc.

Windows 11 Pro, i7-8700 (6 cores/12 threads), CPython 3.12.14, WinLibs GCC 15.2.0 r7, Ninja Release configuration, CMake 4.4.4; BUILD_TESTING=ON, ANYPS5_RELINKER_ONLY=ON.

  • Baseline main 5ee94cf571c71de79b9e28759a72400001b9ab48: the original 53 cases pass in 82.719 s. With a local 30 s CTest limit, the single group times out at 30.066 s.
  • This head: direct whole-file invocation passes all 54 cases in 81.289 s. Independent discovery confirms all 53 original cases occur exactly once, plus the new selection test; six groups of nine cases.
  • All six CTest groups pass in each of three runs with --parallel 2 --timeout 30. Maximum group times per run: 21.110 s, 21.749 s, 20.325 s. No failures or skips. Each group also has an explicit TIMEOUT 30 property.

This supports the local per-process margin from the split, not a reduction in total fixture work or a CI timing guarantee. I configured the relinker-only project but did not compile or run native targets, the full Windows suite, GPU tests or a title. These are pinned branch-head results, not a combined build with current main or the alternative #5685.

AI-assisted: yes (Codex); tests and results reviewed in this session.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6163784036 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678#issuecomment-6163784036). Originally posted by [ideabsassistenza](https://github.com/ideabsassistenza) on 2026-10-14T08:03:14Z. --- Independent Windows validation of head `326845537d12790bdd031efe94f06d8c37f6c5fc`. Windows 11 Pro, i7-8700 (6 cores/12 threads), CPython 3.12.14, WinLibs GCC 15.2.0 r7, Ninja Release configuration, CMake 4.4.4; `BUILD_TESTING=ON`, `ANYPS5_RELINKER_ONLY=ON`. - Baseline main `5ee94cf571c71de79b9e28759a72400001b9ab48`: the original 53 cases pass in 82.719 s. With a local 30 s CTest limit, the single group times out at 30.066 s. - This head: direct whole-file invocation passes all 54 cases in 81.289 s. Independent discovery confirms all 53 original cases occur exactly once, plus the new selection test; six groups of nine cases. - All six CTest groups pass in each of three runs with `--parallel 2 --timeout 30`. Maximum group times per run: 21.110 s, 21.749 s, 20.325 s. No failures or skips. Each group also has an explicit `TIMEOUT 30` property. This supports the local per-process margin from the split, not a reduction in total fixture work or a CI timing guarantee. I configured the relinker-only project but did not compile or run native targets, the full Windows suite, GPU tests or a title. These are pinned branch-head results, not a combined build with current main or the alternative #5685. AI-assisted: yes (Codex); tests and results reviewed in this session.
Amoenus commented 2026-10-14 08:14:05 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Amoenus on 2026-10-14T08:14:05Z.


Windows validation of head 326845537d12790bdd031efe94f06d8c37f6c5fc against main 1209d370723d439477ad10940ebd1163b6873501:

  • Windows 11 Enterprise 26200, Ryzen 9 9950X3D, Python 3.13. Exported the exact test, checker and NID-registry Git blobs; checker/registry are identical between main and this head.
  • Original main module: 53 cases pass, 28.729s reported by unittest (28.926s process time). This head's direct invocation: 54 cases pass, 28.666s (28.838s process time).
  • All six --shard INDEX/6 invocations pass five rounds with two concurrent processes. Each runs nine cases; all 54 run each round. Maximum process time 9.295s, maximum unittest time 9.129s, with a 30-second process limit.
  • Six malformed/index/count argument controls all return exit 2.

This checks the exported Python runner on Windows, not a CMake configure/full application/CI-runner pass. An initial timing-harness bug occurred after shard execution; the corrected campaign above completed and its logs are retained.

This PR was opened before our overlapping #5685 and provides more margin than our three-group split. I am closing #5685 as a duplicate and updating #5672 to point here. AI-assisted: Codex; author responsible.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6163958218 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678#issuecomment-6163958218). Originally posted by [Amoenus](https://github.com/Amoenus) on 2026-10-14T08:14:05Z. --- Windows validation of head `326845537d12790bdd031efe94f06d8c37f6c5fc` against main `1209d370723d439477ad10940ebd1163b6873501`: - Windows 11 Enterprise 26200, Ryzen 9 9950X3D, Python 3.13. Exported the exact test, checker and NID-registry Git blobs; checker/registry are identical between main and this head. - Original main module: 53 cases pass, 28.729s reported by unittest (28.926s process time). This head's direct invocation: 54 cases pass, 28.666s (28.838s process time). - All six `--shard INDEX/6` invocations pass five rounds with two concurrent processes. Each runs nine cases; all 54 run each round. Maximum process time **9.295s**, maximum unittest time **9.129s**, with a 30-second process limit. - Six malformed/index/count argument controls all return exit 2. This checks the exported Python runner on Windows, not a CMake configure/full application/CI-runner pass. An initial timing-harness bug occurred after shard execution; the corrected campaign above completed and its logs are retained. This PR was opened before our overlapping #5685 and provides more margin than our three-group split. I am closing #5685 as a duplicate and updating #5672 to point here. AI-assisted: Codex; author responsible.
MarcZX10 commented 2026-10-14 13:14:31 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-14T13:14:31Z.


Rebased the existing branch onto current upstream/main 63fb0cd92 and resolved the CMake registration overlap by retaining main’s unwrap_self test while replacing the conventions test with six shards. The rebased commit remains authored by MarcZX100 with no coauthor trailer. Validation on Linux/GCC 12.2: relinker-only CMake configure passed; all six conventions_function_bodies shards passed under CTest (--parallel 2, 1.92 s total); tools/check_conventions.py --base upstream/main --head HEAD and git diff --check passed.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6169212840 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678#issuecomment-6169212840). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-14T13:14:31Z. --- Rebased the existing branch onto current upstream/main `63fb0cd92` and resolved the CMake registration overlap by retaining main’s `unwrap_self` test while replacing the conventions test with six shards. The rebased commit remains authored by MarcZX100 with no coauthor trailer. Validation on Linux/GCC 12.2: relinker-only CMake configure passed; all six `conventions_function_bodies` shards passed under CTest (`--parallel 2`, 1.92 s total); `tools/check_conventions.py --base upstream/main --head HEAD` and `git diff --check` passed.
MarcZX10 commented 2026-10-14 13:19:43 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-14T13:19:43Z.


Hosted verification is complete on this rebased head. The Ubuntu, macOS, and Windows relinker jobs all pass; conventions and eligibility pass. The app build jobs are skipped by the PR path filter because this change only affects relinker convention tests. The local six-shard CTest run and convention checker also pass.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6169313589 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678#issuecomment-6169313589). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-14T13:19:43Z. --- Hosted verification is complete on this rebased head. The Ubuntu, macOS, and Windows relinker jobs all pass; conventions and eligibility pass. The app build jobs are skipped by the PR path filter because this change only affects relinker convention tests. The local six-shard CTest run and convention checker also pass.
adriadam10 commented 2026-10-15 11:59:50 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-15T11:59:50Z.


Checked the six --shard INDEX/6 runs on the PR merged onto current main (10 cases each, all pass), the whole module (60 cases, pass), invalid shard arguments (6/6, 0/0, x exit 2) and the coverage test (every discovered case assigned exactly once, no empty shard). conventions_function_bodies keeps its name for shard 0 and all shards keep the 30 s timeout. The Windows runs from @ideabsassistenza and @Amoenus cover the timing scenario from #5672. Merging.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6191525812 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678#issuecomment-6191525812). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-15T11:59:50Z. --- Checked the six `--shard INDEX/6` runs on the PR merged onto current main (10 cases each, all pass), the whole module (60 cases, pass), invalid shard arguments (`6/6`, `0/0`, `x` exit 2) and the coverage test (every discovered case assigned exactly once, no empty shard). `conventions_function_bodies` keeps its name for shard 0 and all shards keep the 30 s timeout. The Windows runs from @ideabsassistenza and @Amoenus cover the timing scenario from #5672. Merging.
github-actions[bot] commented 2026-10-15 12:08:35 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-15T12:08:35Z.


Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
#674 CMakeLists.txt
#1835 CMakeLists.txt
#3891 CMakeLists.txt
#4156 CMakeLists.txt
#4396 CMakeLists.txt
#4397 CMakeLists.txt
#4422 CMakeLists.txt
#4423 CMakeLists.txt
#4424 CMakeLists.txt
#4520 CMakeLists.txt
#4521 CMakeLists.txt
#4522 CMakeLists.txt
#4523 CMakeLists.txt
#4566 CMakeLists.txt
#4599 CMakeLists.txt
#4718 CMakeLists.txt
#4740 CMakeLists.txt
#4749 CMakeLists.txt
#4760 CMakeLists.txt
#4813 CMakeLists.txt
#5021 CMakeLists.txt
#5835 CMakeLists.txt
#6044 CMakeLists.txt
#6067 CMakeLists.txt
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6191685518 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5678#issuecomment-6191685518). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-15T12:08:35Z. --- <!-- pr-overlap --> Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap. | Pull request | Shared files not compared | |---|---| | #674 | `CMakeLists.txt` | | #1835 | `CMakeLists.txt` | | #3891 | `CMakeLists.txt` | | #4156 | `CMakeLists.txt` | | #4396 | `CMakeLists.txt` | | #4397 | `CMakeLists.txt` | | #4422 | `CMakeLists.txt` | | #4423 | `CMakeLists.txt` | | #4424 | `CMakeLists.txt` | | #4520 | `CMakeLists.txt` | | #4521 | `CMakeLists.txt` | | #4522 | `CMakeLists.txt` | | #4523 | `CMakeLists.txt` | | #4566 | `CMakeLists.txt` | | #4599 | `CMakeLists.txt` | | #4718 | `CMakeLists.txt` | | #4740 | `CMakeLists.txt` | | #4749 | `CMakeLists.txt` | | #4760 | `CMakeLists.txt` | | #4813 | `CMakeLists.txt` | | #5021 | `CMakeLists.txt` | | #5835 | `CMakeLists.txt` | | #6044 | `CMakeLists.txt` | | #6067 | `CMakeLists.txt` |
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
boykopovar/AnyPS5!5678
No description provided.