Skip to content

test(ci): scale the hotkey large templates by the parity level (#3109) - #3110

Merged
zackees merged 2 commits into
masterfrom
test/3109-hotkey-large-template-scale
Oct 30, 2026
Merged

zackees merged 2 commits into
masterfrom
test/3109-hotkey-large-template-scale

Conversation

@zackees

@zackees zackees commented Oct 30, 2026

Copy link
Copy Markdown
Member

Fixes #3109.

RED

e88aadafe: obs_c_oracle::parity::scaled_size is a todo!() stub and
large_templates_match_c routes its three fixed sizes through it. The new
parity_cases::fixed_sizes module fails on the stub:

tests::oracle::parity_cases::fixed_sizes::full_keeps_the_written_size
  panicked at rust/obs-c-oracle/src/parity.rs: not yet implemented:
  scale the fixed input size by `level`
Summary [0.015s] 5 tests run: 0 passed, 5 failed

large_templates_match_c itself is the test that timed out in the queue:
merge-queue run 41133193773 reported
TIMEOUT [30.008s] hotkey::translations_parity::large_templates_match_c,
and the next green run reported the same test SLOW [> 10.000s].

GREEN

b7bf21108: scaled_size / scaled_size_at return the written size at
full (local, nightly, release) and the same share the case counts keep
otherwise — 10 % at reduced (PR, merge queue) — never below one element,
so an input is never empty. large_templates_match_c builds a tenth of its
1 MiB template, its 100000-repeat string and its 64 KiB padding on the
queue, which still overruns struct obs_hotkeys_translations by far, so the
C-vs-Rust comparison and the overflow path are unchanged.

The test's sizes are deterministic, not a proptest, so this is the same
mechanism obs_c_oracle::parity::scale already gives the case counts (#2593,
#2888), not a change to what the test asserts.

Test cost

This machine, debug build, the module alone in obs-tests-core:

OBS_PARITY_CASES time
full (old cost on every run) 7.725 s
reduced (new Fast Gate cost) 0.357 s

Speedup ≈ 21×. The Fast Gate runs the default nextest profile at the
reduced level, so the 30 s budget has room even under the 6-thread
oversubscription from #3071. No own threads; peak RSS unchanged in kind (the
largest buffer drops from 1 MiB to 105 KiB).

Tiers

  • Tier 1: the new parity_cases::fixed_sizes unit tests (5 cases).
  • Tier 2/3: unchanged behavior — the module still compares the Rust parser
    against the C oracle on the same struct; only the input sizes scale.
  • Tier 4: not applicable (test-only change).

Refs #3012, #2888, #3071.

zackees and others added 2 commits October 30, 2026 15:50
RED: `obs_c_oracle::parity::scaled_size` is a `todo!()` stub, its unit
test fails, and `large_templates_match_c` routes its three fixed sizes
through it so the Fast Gate can build a tenth of them.

Co-Authored-By: Hermes Agent <[email protected]>
GREEN: `scaled_size_at` returns the written size at `full` and the same
share the case counts keep otherwise (10 % at `reduced`), never below one
element. `large_templates_match_c` builds a tenth of its 1 MiB, 100000-
repeat and 64 KiB inputs on the merge queue, which keeps the overrun of
the struct and the C-vs-Rust comparison.

Measured in the debug build, this machine, the module alone:

  OBS_PARITY_CASES=full     7.725 s
  OBS_PARITY_CASES=reduced  0.357 s

Co-Authored-By: Hermes Agent <[email protected]>

@zackees zackees left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coordinator review: correct. scaled_size_at mirrors scale: full is unchanged, otherwise it keeps the same percent, with a floor of one so no input is empty. The RED stub (e88aada) and then the GREEN commit (b7bf211) are visible. Even at a tenth, the reduced template still overruns struct obs_hotkeys_translations, so the test keeps its point. This is the same class of fix as #3103 (case counts) for fixed-size tests. It changes no behavior, so no ledger line is needed.

@zackees
zackees enabled auto-merge October 30, 2026 23:07
@zackees
zackees added this pull request to the merge queue Oct 30, 2026
Merged via the queue into master with commit 3df7c10 Oct 30, 2026
79 of 81 checks passed
@zackees
zackees deleted the test/3109-hotkey-large-template-scale branch October 30, 2026 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

test(ci): hotkey large_templates_match_c crosses the 30 s budget in Fast Gate and turns queue runs red

1 participant