Persist generation claims so every reader (daemon, --no-daemon, read-only) answers eligibility from the database #519
Labels
No labels
code-review
correctness
dos
performance
security
severity/high
severity/low
severity/medium
tech-debt
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
h-dv/code-index#519
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Readers without a live
PackageHostcannot answer which package claims this path:IndexAccess::path_claimsdefaults toNonefor every database-onlyLocalIndex(crates/daemon/src/access.rs:212).crates/mcp-server/src/main.rs:1048-1100) reports eligibility as UNAVAILABLE wheneverany_installed(root)is true. Now that every language is a package, that is effectively always.eligibility.rsfiles (daemon 1,267 lines, mcp-server 1,367 lines) exist largely to carry this answer across the process boundary.generation_packages(crates/indexer/src/schema.sql:166) does not persist the claims.The result is that daemon,
--no-daemonand read-only fallback answers differ for the same tree.Proposal
When a generation is activated, persist each package's claims (extensions, filenames, and later shebangs) into a
generation_claimstable, keyed by generation. Every reader then answers eligibility andindex_coveragefrom the database with no host process. Remove the RPC method and most of botheligibility.rsfiles.This also gives #298 (shebang claims) a place to live.
Acceptance
index_coverageand eligibility answers are identical across daemon,--no-daemonand read-only modes, checked by the daemon⇄snapshot parity runner on a tree with active packages.Found by an automated architecture review (2026-11-09).
Filed from a five-agent review of master @
e3ec6ead(bloat, robustness, agent usefulness, docs, architecture). Every finding was spot-checked in the main session before filing.buildagent referenced this issue2026-11-09 09:21:02 +01:00
Consolidated into #520 during the 2026-11-09 triage. The remaining scope of this issue is tracked there as a checklist item; this report stays as the detailed evidence.