Repository navigation
fix(perception): count every WorkbenchPool overflow frame (#538) - #637
Conversation
…D3-F02) [WIP] Owner ruling (#538 comment 6393037794): keep latest-wins / drain-all; drops = frames actually dropped, overflow_events = overflows, discarded_on_stop separate, per-stream frame identity and gaps, no unrecorded drop under concurrent producers. - put_frame holds a per-stream lock across its state re-check and the whole drain-and-enqueue; stop() drains under the same locks, so every frame is counted exactly once (dropped / dequeued / discarded / queued). - drops += frames drained, overflow_events += 1; telemetry workbench_drops gets the frame count, plus workbench_overflow_events. - frames carry a per-stream seq; the worker counts dequeues and gaps; get_stats()["streams"] exposes the per-stream counts. Not pushed: with several producers on the same stream the lock also changes delivery (more frames reach the worker); held for the owner. Docs (§27), mutation, Codex and the runtime capture are not done yet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019RVti7Gf7paqtEzERmZaCx
Implementation 11263f7c -> 0cb15155; only dispatcher.py changes. Decision surface, environment, identity semantics and runtime inputs are unchanged. Fresh MOT17-09 probe at a06f56a has digest 2dabed0b; equality is not equivalence (unproven). Archive the exact outgoing publication; this two-file commit must co-land atomically with the F02 implementation after review.
…ty-review chore(runtime): publish #538 F02 coordinate with exact outgoing archive
raylei50653
left a comment
There was a problem hiding this comment.
Independent review — APPROVE
Reviewer: separately authorized read-only Codex review agent /root/f02_independent_review; this is an independent session review, not a GitHub account approval.
- Implementation base: aa69c3c
- Implementation reviewed head: 83252ce
- Publication reviewed head: 1ef62df
- Verdict: APPROVE for both heads.
- Findings: no actionable or blocking findings; no unresolved dispositions.
The reviewer checked per-stream serialized admission/drain/enqueue, actual frame accounting versus overflow events/stop discards, frame identity/gaps/reset/restart, bounded stop lock acquisition and partial-drain retry. Publication changes exactly canonical + archive. Archive equals base bytes (SHA-256 d740889a2fe15e58bd868a9af5b8e9ae23b033c76cca1caa068562e65407d85b); canonical equals scratch candidate (f36316235124b7edde843e262b46248299b99077f25aa47c50e1784d51bdb5b2). Implementation members 319 -> 319; only dispatcher.py changed; four other axes unchanged; complete=true, equivalence=unproven. Both native artifact bytes match build witnesses.
Independent checks: 8 new CPU contracts passed (1 GPU deselected); strict attested validation with retained fresh verification probe and complete runtime-input manifest exited 0 on the GPU host. All evidence hashes, 43-test JUnit (13 CUDA cases, zero skips/failures), and the six intended mutant assertion failures were verified. Earlier full pre_push logs and the resolved .venv path failure classification were verified.
Limits: reviewer did not rerun the full GPU suite or recapture MOT17-09; those retained artifacts were audited and strict attestation revalidated. CUDA contract tests use real Workbench/batcher with substituted TRT inference. No online qualification, performance or semantic-equivalence claim. Required final-head checks, PR CI, §0A self-check and atomic landing remain separate gates; changed heads require delta review.
Publication review is also recorded on #636, now merged into this implementation branch. The combined merge commit is 39ddb39; its content-identical delta is undergoing independent review.
|
Final-head local validation Head:
Command: UV_NO_SYNC=1 UV_CACHE_DIR=/tmp/saccade-550-uv-cache \
PYTHONDONTWRITEBYTECODE=1 \
PYTHONPATH=/tmp/saccade-550-f02/build/runtime_identity:/home/ray/developer/ai/saccade/build/runtime_identity:/home/ray/developer/ai/saccade/.worktrees/550-f02-validation/src \
bash scripts/pre_push.shLog The earlier failure was the existing import-witness test resolving a symlinked .venv outside the checkout; using a real in-checkout dependency directory at the same head resolved it without changing or skipping a test. Both first-failure and successful rerun logs/hashes remain recorded in §10. This final run directly tests the reviewed publication head and supersedes the earlier documentation-only delta qualification. After #636 merged, combined head is |
raylei50653
left a comment
There was a problem hiding this comment.
Independent delta review — APPROVE
Exact reviewed combined head: 39ddb39b3ad5592ba6713cc9e0c84961caaa6afa.
Reviewer: the same independent read-only Codex review session; findings: none; disposition: no correction required.
Verified parents are 83252ceea451a6b223d8d0eb4bfc1a8e6d1077d3 and 1ef62df872c0bad2798b6a39a274de2b6081a781; both and base aa69c3c1caf502ecc5aeeda92f90d8db6871a6c3 are ancestors. Tree 9ac7f0620974fc7680f6ce825b88aef63dae176a is byte-identical to the reviewed publication head; full diff is empty. Relative to implementation head, only canonical + archive are added. All previously verified source/test/candidate/archive hashes remain unchanged.
The reviewer independently checked the final pre_push log and its SHA-256 493c62bc63a561114d560526246e1e64b1becc6b470501590d1fdcc496a68bd0: 6242 passed, 195 skipped, 105 deselected, 5 xfailed, 0 failed, 496.85 seconds, all checks passed. Validation checkout remains clean at 1ef62df; identical tree binds that result to this merge head.
This is a content-empty delta review; no full test rerun was performed by the reviewer. Original GPU/qualification limits remain. Required CI on this exact landing head, §0A self-check and atomic main merge are the remaining delivery gates.
|
#550 §0A merge self-check — READY Reviewed landing head:
Merge authorization is #550 §0A standing authorization. Merge is constrained to the exact reviewed head above. |
|
Post-merge verification — main GitHub confirms #637 merged. Parents are Additional strict check on merged main: PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=src \
SACCADE_BUILD_PATH=/tmp/saccade-550-f02/build/runtime_identity \
.venv/bin/python scripts/tools/check_runtime_identity_staleness.py \
--mode attested --strict \
--probe-from /tmp/saccade-550-f02-evidence/verification-probe.json \
--runtime-inputs-from /tmp/saccade-550-f02-evidence/runtime-inputs.jsonRun from clean First attempt is retained and classified: running the same supplied full manifest from the other checkout Main CI and C++ are SUCCESS, 8/8 checks, bound to exact merge 6ca331d. Main pytest: 6083 passed, 294 skipped, 105 deselected, 4 xfailed, 0 failed (886.88 seconds). Both main workflows passed on the first run. Existing OPEN items and qualification limits remain as in the pre-merge self-check. |
Summary
WorkbenchPool 清掉滿 queue 的 4 幀時,原本只記
drops=1。本 PR 保留 latest-wins/drain-all,將 drops/telemetry 改為實際丟棄幀數,另計 overflow_events、stop discard,以及各 stream 的連續 frame identity/可觀察 gap。並行 producer 的 drain-and-enqueue 以 per-stream lock 保護。新的 admission lock 也納入 stop deadline;取得鎖逾時會保留資源、維持 STOPPING 並允許重試,已完成的部分清理不遺失也不重複計數。鎖可能改變競爭時實際交付的幀集合;沒有輸出/吞吐等價宣稱。
需求與選擇:owner F02 裁決、方案與交付紀錄。契約、首次失敗分類、真實 GPU 證據與 SHA-256 在 async_ownership_538.md §10。Refs #538、#550;本 PR 不關閉 parent issue。
Decision-layer change?
不修改 headline preset、eval schema/defaults、pipeline inject、tracker 決策 kernel 或 decision docs。dispatcher.py 屬 decision_relevant,風險為高:runtime identity 已經獨立兩檔 publication PR #636 審查並合入本 branch。本 PR 將實作與 coordinate 一次原子合入 main。
Behavior change?
既有 offline eval/tracker 行為沒有修改;MOT17-09 identity probe 不被當成 7-seq performance/online qualification。
Adding, tightening, or retiring a check?
新增 regression tests,沒有修改 CI/hook/qualification 標準。
Test plan
39ddb39b3ad5592ba6713cc9e0c84961caaa6afa的獨立 delta review 也 APPROVE。39ddb39b3ad5592ba6713cc9e0c84961caaa6afa的 required/適用 CI 8/8 通過;[Hub] SACCADE 工作總入口:進度、優先序、依賴與 checkpoint #550 §0A self-check 已貼於本 PR。Remaining OPEN:online qualification、F04 watchdog、F05 ingest drops、多 worker NMS capture 等既有殘留;未清除 #340 trace。distribution local-only、equivalence unproven。回退須同時回退實作並依 runbook 重發 coordinate。
Combined head:
39ddb39b3ad5592ba6713cc9e0c84961caaa6afa;tree9ac7f0620974fc7680f6ce825b88aef63dae176a與已審查、完整測試的1ef62df872c0bad2798b6a39a274de2b6081a781完全相同。main baseaa69c3c1caf502ecc5aeeda92f90d8db6871a6c3。遠端 CI/C++ 全綠;pytest 6083 passed/294 skipped/105 deselected/4 xfailed/0 failed。