Skip to content

fix: pre-release review — 7 surgical fixes#100

Merged
jamestexas merged 1 commit intomainfrom
fix/pre-release-review
Mar 16, 2026
Merged

fix: pre-release review — 7 surgical fixes#100
jamestexas merged 1 commit intomainfrom
fix/pre-release-review

Conversation

@jamestexas
Copy link
Copy Markdown
Contributor

Summary

Pre-release audit found 7 issues (3 blockers, 4 should-fix). All resolved in this PR:

  1. SQL injection in daemon query path (P0) — symbol parameter sanitized before interpolation into SQL sent over UDS
  2. VFS handler hides graph nodes named "context"/"location" (P0) — Resolver now falls through when Match succeeds but Stat returns nil
  3. release.yml repository_dispatch never creates a release (P0) — Condition now checks client_payload.tag
  4. WritableGraph.ListChildren selects name instead of id (P1) — Fixed to match SQLiteGraph
  5. lazyGraph.cleanup never called (P1) — Added graphRegistry.Close(), deferred in runServe
  6. Managed leyline daemon orphaned on exit (P1) — Signal handler for SIGTERM/SIGINT
  7. Unbounded batch read_file (P1) — Capped at 100 paths

Beads: mache-5c416f, mache-5c4c3b, mache-5c5366, mache-5c5a44, mache-5c6836, mache-5c6f1b, mache-5c76b3

Changes since v0.5.6 (24 commits)

Test plan

  • task build — compiles clean
  • task test — all tests pass
  • CI passes
  • Verify VFS fallthrough with a Go project containing a context package

🤖 Generated with Claude Code

1. fix(serve): sanitize symbol input in daemon SQL queries to prevent injection
2. fix(vfs): resolver falls through to next handler when Match succeeds but
   Stat returns nil — prevents real graph nodes named "context"/"location"
   from being hidden by virtual file handlers
3. fix(ci): release.yml repository_dispatch condition now checks
   client_payload.tag so leyline-triggered releases actually publish
4. fix(graph): WritableGraph.ListChildren selects id instead of name,
   matching SQLiteGraph behavior for correct path resolution
5. fix(serve): graphRegistry.Close() calls cleanup on all lazy graphs,
   wired via defer in runServe to prevent SQLite connection leaks in HTTP mode
6. fix(serve): signal handler for SIGTERM/SIGINT ensures managed leyline
   daemon is stopped even when process is killed rather than exiting cleanly
7. fix(serve): cap batch read_file to 100 paths to prevent unbounded requests

Beads: mache-5c416f, mache-5c4c3b, mache-5c5366, mache-5c5a44,
       mache-5c6836, mache-5c6f1b, mache-5c76b3

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@jamestexas jamestexas enabled auto-merge (squash) March 16, 2026 07:21
@jamestexas jamestexas merged commit 93881d3 into main Mar 16, 2026
12 checks passed
@jamestexas jamestexas deleted the fix/pre-release-review branch March 16, 2026 07:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant