mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #5269] [Benchmark] Windows: concurrent_round wall clock (GetTickCount64, 15.6 ms) measures 0.0 s, aggregate_tps becomes null #3137
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#3137
Loading…
Add table
Add a link
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?
Originally created by @yeyeyeason on GitHub (Nov 5, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5269
Area
[Benchmark] (measurements and reports)
Desktop app, Terminal or source?
Source (START-HERE.bat, setup.sh or a build)
What happened
tests/terminal/test_bench_standard.py::RunTests::test_a_round_total_is_null_when_a_counted_request_has_no_token_countfails on Windows withAssertionError: unexpectedly None(line 696,assertIsNotNone(doc["concurrency_rounds"][0]["aggregate_tps"])).The cause is not the missing usage entry the test models. Every concurrent request completes (
status: completed,failed: 0,output_tokenspresent), but the round'swall_sis 0.0: on this Windows machine Python'stime.monotonic_ns()is backed byGetTickCount64()with a 15.625 ms resolution:The mock server answers in under one tick, so all four threads'
t0andt_endland on the same tick andmax(t_end) - min(t0)is 0. Thewall > 0guard instrata_cli/bench_standard.py:555then setsaggregate_tpsto null. Probe runs through the test's own machinery (5 repetitions, 15 rounds): 9 of 15 rounds measured 0.0 s; the rounds that passed had merely crossed one tick.On Linux
monotonic_nsis nanosecond-resolution, sowallis never 0 and the suite passes — this is a Windows-only measurement defect in the bench/test infrastructure, not an engine or protocol problem.Smallest steps or command that reproduce it
From a v0.2.10 checkout on Windows (Python 3.12.10, pytest 9.2.0):
Result here: 66 passed, 2 failed (this issue and the timeout-classification one), twice in a row.
Reproduction status
Reproduced locally
Strata version
v0.2.10 checkout, commit
ffa80d73(no engine involved: the failing tests run against the mock server)Graphics card, memory and system
RTX 4060 Ti 16 GB x2 · 96 GB RAM · Windows 11 Pro (no GPU is used by these tests)
Model, size and settings
Not applicable — the failure is in the mock-server test path.
Logs
Probe output (the test's own run, five repetitions):
(each tuple: round, wall_s, aggregate_tps)
A possible fix would be stamping
t0/t_endwithtime.perf_counter_ns()(QPC on Windows, high-resolution elsewhere; the values are only differenced within one request). Happy to prepare that PR if the direction is agreed.