Fix-heavy release. Everything under "serve write path" was root-caused on a live multi-agent store where trovex_write and trovex_search timed out at 30s while the process sat at 300-400% CPU. Each entry names the actual cause.
Fixes — trovex serve write path
- SQLite write concurrency: WAL mode,
busy_timeout, and retry/backoff onSQLITE_BUSYforput/delete. Two agents (or two devs on one store) writing at the same time no longer fail with "database is locked". (ebd5f60) - Stranded write transactions no longer wedge the store. A client disconnect mid-request, or a KNN query with k > 4096, used to leave an open write transaction holding the lock. (2a54453)
- MCP tool handlers run off the event loop. Every
@mcp.tool()ran inline, so one slow DB call froze every other MCP request. (33ca98a) Same fix for FastAPI's own routes, confirmed from a thread dump of the wedged process. (2af4cee) Same fix for@mcp.resourcehandlers, the last inline path. (d3b0cd6) - Reindex is single-flight and readers stay responsive while it runs.
/api/reindexno longer executes inline on the event loop, and a second concurrent request is refused instead of stacking. (3bce1da) - WAL checkpoint switched from
TRUNCATEtoPASSIVE.TRUNCATEneeds exclusive access and busy-waited up tobusy_timeoutafter every commit; with concurrent readers that was the direct source of the 30s timeouts. (457c8a0) .worktrees/and other dotted ignore dirs are pruned from the corpus walk again.ignore_dirslisted the bare name while the walk compared the dotted one, so every linked git worktree was re-scanned on each reindex and the WAL grew past the DB itself. (5acfccd)- Reindex commits on a 1s timer (
REINDEX_COMMIT_INTERVAL_SEC) instead of a count-based batch that never fired on a mostly-unchanged corpus. The writer lock is now held for under a second at a time. (2d23c39) sweep_bloat,sweep_retention, andreconcile_vec_metatake the in-process store lock per 200-doc batch instead of across the whole pass. Last layer of the wedge. (09e298f)- Timing hardening for the concurrent-write-during-
compute_statustest. (8bf75f6, f13982d)
Features
- Blind-judged eval harness for the savings claim:
trovex eval-harness <corpus> --retrieval-only --gate. The judge never sees which side is trovex. The token-savings number now comes from this harness, not from the binarybench --eval. (9dc098f)
CI
skill-gateworkflow uses a general left-anchored review-verdict regex with a pinned selftest, so domain-scoped review skills pass the check. (f217207)
Upgrade
uv tool upgrade trovex # or: uvx trovex@0.15.0
Restart trovex serve afterwards. No store migration is needed; the fixes were rolled onto an existing production store in place.
Full Changelog: v0.14.0...v0.15.0