tools: conventions_function_bodies approaches 30s and times out in the Windows full suite #5672
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by Amoenus on 2026-10-14T05:52:01Z.
What
conventions_function_bodiesapproaches the30s test budget and timed out under a full Windows CTest run. It registers the entire53-casetools/tests/test_check_conventions_comments.pyas one process.Observed evidence
a14ae8e232b100eab53c6cdce0676ff167fd137b: full1163 tests,1154 pass,8 existing skips,1 timeout.conventions_function_bodiestimed out at 30.0414s; full run265.55s.0b6d033b80083ca4468c38c4b7e88053eb238d01: Git blobs25e0b1f871cc7dda7c98e2a9dc0174beac26f38a,61b187c984969f26b661dfe5d52d673287097891,2cb0d756e4146907878c42b1205ee77b0f008566.Reproduction
Windows11 Enterprise26200, Ryzen9950X3D, Python3.13, WinLibs GCC15.2.0r7/Ninja Release, testing enabled, bundled dependencies. Full runtime build; parallel2 as below. Exact timings are load dependent.
Current registration runs the whole file. The contribution guide requires splitting or shrinking tests close to30s, accounting for concurrent CTest load.
Proposed correction
Use the earlier #5678, head 326845537. Exact exported test/checker/NID-registry files run on Windows11/Python3.13: main1209's53 cases pass28.729s (28.926s process), this head's54 pass28.666s (28.838s process). Six nine-case shards pass five rounds with two concurrent Python processes and a30s limit: maximum9.295s process/9.129s unittest. All54 cases run every round; six invalid CLI controls exit2. This is direct Python-runner validation, not CMake/full application/CI validation. An initial timing harness shadowed Python's round function after shard execution; the corrected campaign completes and original logs remain.
Our later overlapping #5685 is closed in favor of #5678. Both implementations and validation are preserved; no duplicate upstream fix is needed.
Earlier alternative and validation (preserved)
Split the registration into smaller complete unittest groups, retaining all53 cases and future discovery coverage, with the same30s bound. Confirm the partition covers the original case set and compare main/change runs. The implemented proposal is #5685, fork dbc2ab33c, based on main107. It preserves the original53 cases, adds three partition checks, and keeps direct whole-file invocation. Full relinker-only build, conventions/registration and five adjacent groups pass. Three groups pass five repetitions with parallel2 (maximum16.4823s); the post-rebase run passes at maximum19.62s. The exported unmodified-main53-case invocation passes in27.072s; the candidate default56-case invocation passes in27.984s. These establish local per-process margin, not deterministic CI timing or a whole-main timeout reproduction. No timeout increase, retry or environment switch.
At the initial report, searched existing issues/PRs for the test name, script path, conventions/timeout and conventions/split. Other reports mention this timeout, but no dedicated report or split contribution was found then. #5678 is now confirmed as the earlier overlapping submission; the current proposal above points to it.
AI-assisted: yes (Codex); author responsible.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-14T06:04:53Z.
Opened #5678 with six deterministic shards over all discovered tests; a coverage test checks every case is assigned once, including future cases. On Linux the six CTest shards pass. I have not run the reported Windows full-suite scenario, so that remains the platform-specific validation to check.
Imported from boykopovar/AnyPS5. Originally posted by jotitadev on 2026-10-15T18:52:05Z.
#5678 (merged) registers
test_check_conventions_comments.pyas six CTest shards (conventions_function_bodiesplusconventions_function_bodies_shard_1.._5,--shard N/6, 30 s timeout each), and #5748 (merged) reads the checker's file contents through onegit cat-fileprocess.macOS data point on
main44df21632: Apple M2 Max, relinker-only build (-DANYPS5_RELINKER_ONLY=ON -DBUILD_TESTING=ON),/usr/bin/python33.9.6.ctest -R "^conventions_function_bodies" -j6 --timeout 30: 6/6 pass, slowest shard 4.8 s.python3 tools/tests/test_check_conventions_comments.py): OK in 17.6 s.I have not rerun the Windows full-suite case from the report.
Written with AI assistance (Claude Code). I ran the check above on my machine.
Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-16T23:53:41Z.
Fixed by #5678 (
646c6a248) and #5748: the checker now runs as six CTest shards of 30 s each, and the shard timings on current main are well under that (slowest 4.8 s on an M2 Max, 6/6 passing). I haven't seen a Windows full-suite run after the merge; if it still times out there, reopen with the shard timings.