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 }}
This repository was archived by the owner on Jul 13, 2026. It is now read-only.
Repository navigation
Commit 595629b
Browse filesBrowse the repository at this point in the historyBrowse files
fix(audit): full-codebase council round — 9 real fixes + false-positive dispositions
Verified all 19 findings against source (2 empirically). 9 real bugs fixed, 8
false positives documented, 2 deferred-by-design.
REAL FIXES:
- cortexkit#3 (High) m[0]/m[1] fail-open dropped ALL history: prepareCompartmentInjection
splices raw history out BEFORE postprocess injectM0M1; if injectM0M1 threw, the
log-only catch left the model with neither raw history nor <session-history>.
Now falls back to renderCompartmentInjection (legacy block) in the catch.
OpenCode-only — Pi's injectM0M1Pi trims+prepends atomically after all throws.
- cortexkit#5 (Med) key-files break→continue: rows arrive generated_at DESC/path ASC (not
importance), so a break let one large alphabetically-early file suppress
smaller later files that fit. Knapsack fit/skip now.
- cortexkit#6 (Med) dream-queue stale cleanup deleted a running entry under an active
lease, and globally (cross-host). Gated on !hasActiveDreamLease + project-scoped
clearStaleEntries(projectIdentity). +2 tests.
- cortexkit#7 (Med) key-file candidate filter used naive startsWith; now uses the
realpath+segment-aware isRelativeProjectFile before seeding the Dreamer prompt.
- cortexkit#9 (Med) Pi maxCompartmentSeq/maxMemoryId used Math.max(...spread) → RangeError
on 100K+ rows. reduce() now (OpenCode uses SQL MAX).
- cortexkit#10 (Med) v22 doctor repair paths did blind UPDATEs → UNIQUE-collision abort on
colliding identities. Shared rekeyMemoryRowWithCollisionMerge (merge-on-collision,
mirrors the main backfill) wired into both doctor functions.
- cortexkit#11 (Med) Pi host CI/release installed unpinned opencode while the OpenCode host
job pins 1.15.4 around the linux-amd64 /doc hang. Pinned Pi jobs to 1.15.4 too.
- cortexkit#12 (Med) release.sh set -e aborted at output=$(bun test) before the Bun
panic-tolerance could run. status=0; output=$(...) || status=$?.
- cortexkit#16/cortexkit#17 (Low) CLI Pi detection which/where → findOnPath; fixed broken
scripts/context-dump.ts import path.
FALSE POSITIVES (verified, documented A14/A20-A23):
- cortexkit#1 Critical clearSession-rollback + cortexkit#2 High user-memory-tables-absent: empirically
DISPROVEN. openDatabase runs initializeDatabase THEN runMigrations; a fresh DB
applies all v1–v26 so plugin_messages (v2) + user_memory_candidates/user_memories
(v3) exist. New storage-db.test.ts asserts all 16 clearSession tables exist fresh
and clearSession removes the row. A14's stated reasoning is correct for
plugin_messages (Grok's counter-claim was the error).
- cortexkit#4 memory-mutation watermark: Sonnet right — softRefreshCachedM1 renders the
<memory-updates> delta via maxMemoryMutationId on the next cache-bust (A15/A20).
- cortexkit#8 post-ROLLBACK read: single atomic SELECT, no torn read (A21).
- cortexkit#14 staleUpdates map / cortexkit#15 merge tier visibility: clear-before-loop / single tx (A23).
DEFERRED-BY-DESIGN: cortexkit#13 Pi O(N^2) sweep (A22), cortexkit#18/#19 info.
Gate: plugin 1731/0 (+3), Pi 403/0, CLI 146/0; tsc + lint clean all three; node:sqlite intact.
0 commit comments