ci: reduce Python test overhead and Windows latency (#6357)

* test: merge overlapping semantic contract coverage

Consolidate the six confirmed NAN-310 overlap groups while preserving replay, usage, generation kwargs, archive metadata, inspect fields, and subagent crash/redelivery assertions.

* test: lighten history seeds and layer runner progress rules

* ci: defer test storage setup and record phase timings

Close each listener-owned binary bridge before waiting for its TCP server; retain active upload and undecided-connection regressions. Avoid consuming readiness twice and run the repository import scan once in its static gate. NAN-310.

* test: scope filesystem mocks and observe consumed socket prefixes

* test: publish subprocess readiness files atomically

* ci: isolate external tool discovery and use three Windows workers
This commit is contained in:
chengyongru authored and GitHub committed 2026-10-21 14:47:55 +08:00
1 parent 743c51e81f
commit f284749d2f
28 files changed
+518 -448

No files matched your search

+11 -11
View File
@@ -359,25 +359,25 @@ def test_many_short_trace_rows_are_bounded_and_resolved(tmp_path, monkeypatch) -
monkeypatch.setattr("nanobot.config.paths.get_data_dir", lambda: tmp_path)
key = "websocket:deferred-many-traces"
trace_count = 2_000
append_transcript_object(
key,
rows = [
{"event": "user", "chat_id": "deferred-many-traces", "text": "run many tools"},
)
for index in range(trace_count):
append_transcript_object(
key,
*(
{
"event": "message",
"chat_id": "deferred-many-traces",
"kind": "progress",
"text": f"tool_{index}(value)",
},
)
append_transcript_object(
key,
}
for index in range(trace_count)
),
{"event": "message", "chat_id": "deferred-many-traces", "text": "done"},
{"event": "turn_end", "chat_id": "deferred-many-traces"},
]
# Replay needs the full stored input, not one durable append per trace row.
transcript_module._write_records_to_path(
transcript_module.webui_transcript_path(key),
[{**row, "created_at_ms": 1_700_000_000_000} for row in rows],
)
append_transcript_object(key, {"event": "turn_end", "chat_id": "deferred-many-traces"})
payload = build_webui_thread_response(key, limit=40, direction="latest")