Repository navigation
tests: four 4108 probe ReDoS checks use the CPU-clock helper (Part of #8423) - #8660
Merged
Merged
Conversation
…8423) Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Contributor
|
No description provided. |
2 of 3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #8423
Checklist: done [c:fe9d3cb3]
The gate (
tests/tools/test_no_raw_wall_clock_timing_8423.py, #8523/#8548) already refuses a new raw wall-clock difference and a stale offender entry. This PR shrinks its list: the api_db_sink, embedded_credentials, global_env_mutation and stego_imports 4108 probes now usetests/_timing.assert_cpu_below(bounds unchanged, 5 s / 2 s).Class
Tests asserting elapsed time with raw
time.perf_counter()differences instead of the shared CPU-clock helper. Same mechanism, left for later:test_vectorized_math_probe_4108(5-file cap), and 15 other listed offenders (pic_run_lengths_7169, translator_pic_runs_7169, cics_macro_level, dense_source_7501/7504, prefetch, c_kernel_vocab_8016, three calls_out_, go_semicolon_imports_6572, redos_poison, secrets_shunt_4987, two tls_bypass_).Sibling gaps
test_prefetchandtest_redos_poisonusemonotonicfor stall logic, so they likely need a gate allowlist, not a conversion.tests/tools/wholesale, so a timing assert there is not caught.Remaining slices
tests/tools/test_*.pyin the gate.Facts checked: the 4 probe files, the gate test and detector test pass (92); also from an unrelated cwd;
audit_check.pyall clear; ruff format clean. No golden impact (tests only).🤖 Generated with Claude Code