You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Follow-ups from #107 review: touch() byte drift, shared walk epoch, sort write-back #108
Follow-ups from the post-merge review of #107 (70c9d0109). The verdict was DEPLOY: nothing here returns wrong data. Full report on shuvdev: ~/.cache/agent-ws/executor-pr107-review-opus-r1.md.
M1 (new in Follow-ups to #105 and #106: walk-cache shared values, never evict a search in use #107, fix forward):packages/sdk/src/implementation/tool-search-store.ts:217-226: touch() can put back an order that was evicted or replaced while its page was being read, without counting its bytes. The 6 MB bound can drift toward about 64 MB (32 × 2 MB). Fix: touch only when orders.get(key)?.order === order. Add a model or e2e of the admit/touch interleavings (rat-stack model-a-protocol).
M3 (already in production):Array.prototype.sort with a comparator writes elements back without the cycle check. Programs can build cycles that later stores accept. The result boundary rejects them cleanly.
NITs: running mcp-search-kept-orders right before mcp-search-walk on the same worker can make the walk scenario flaky; a few doc statements are inaccurate (see the report).
M1 is addressed by #111. N1 is not a bug: the self-host scenario lifecycle starts a fresh server per scenario, so kept-orders and walk do not share the kept-order map. N2 is a doc correction in #111. M2/M3 remain open.
M1 fixed by #111 (merged as b51071ab): a later-page read now refreshes or forgets only the exact order it read. Three E2E race scenarios (mcp-search-kept-order-races.spec.ts) each failed on the old store and pass with the fix, and fork CI now runs them with the existing kept-orders and walk scenarios.
The other findings:
N1 (flaky kept-orders/walk interaction): not a bug. Each scenario starts its own server (e2e/sdk/scenario.ts:91-108), so the two never share a cache.
Activity
shuv1337 commentedon Nov 20, 2026
M1 is addressed by #111. N1 is not a bug: the self-host scenario lifecycle starts a fresh server per scenario, so kept-orders and walk do not share the kept-order map. N2 is a doc correction in #111. M2/M3 remain open.
shuv1337 commentedon Nov 20, 2026
M1 fixed by #111 (merged as
b51071ab): a later-page read now refreshes or forgets only the exact order it read. Three E2E race scenarios (mcp-search-kept-order-races.spec.ts) each failed on the old store and pass with the fix, and fork CI now runs them with the existing kept-orders and walk scenarios.The other findings:
e2e/sdk/scenario.ts:91-108), so the two never share a cache.keptIdleMillisnow gives the real threshold (Fix kept-order byte accounting after concurrent page reads #111).admit. Byte counts and rows stay exact; the cost is one extra ranking.sortwrite-back), N3 and N4.