Skip to content

Give Commit and TypeRef nodes their identities in the file subgraph - #44

Merged
Phoenixrr2113 merged 2 commits into
mainfrom
batch-d-file-route-500
Aug 24, 2026
Merged

Give Commit and TypeRef nodes their identities in the file subgraph#44
Phoenixrr2113 merged 2 commits into
mainfrom
batch-d-file-route-500

Conversation

@Phoenixrr2113

Copy link
Copy Markdown
Owner

What changed

The file detail panel returned HTTP 500 ("Graph node is missing a persisted id") whenever a contained symbol had a Commit neighbor via INTRODUCED_IN, which the history-window batch made much more common. Root cause: Commit nodes are persisted with MERGE on hash and intentionally carry no id property, and persistedNodeId() had no Commit derivation. The fix derives Commit:, exactly matching the existing service-layer lookup contract (graph-data-service composes the same form). Along the way the same query's TypeRef projection was coercing TypeRefs to a false File identity; they now keep their persisted ids and runtime label. A truly unidentifiable adjacent row no longer fails the endpoint: identifiable nodes and edges are returned and the offending row is surfaced in an identityErrors entry with its labels and edge type. Non-identity errors still propagate.

Verification

Red-first regression fixture on a real ephemeral FalkorDBLite database, then an independent review: full sweep of all 527 File nodes on fresh indexes at both 1-commit and complete 516-commit history depth returned zero 500s, zero identity errors, zero malformed ids; the malformed-fixture probe retained 5/5 nodes and 6/6 edges with exactly one diagnostic; graph 208/208, api 365/365, dashboard 124/124, typechecks clean. Verdict: no blockers.

Deliberately not in this PR

Ledger: the identity-error discriminator matches on exact message text (a branded error class would survive future message collisions); the undirected relationship match emits reverse CONTAINS edges (pre-existing projection quirk, no data loss).

🤖 Generated with Claude Code

The file detail panel 500ed when a contained symbol had a git-history
neighbor: Commit nodes are keyed by hash, never id, and the identity
derivation did not know that. Commits now derive Commit:<hash> to match
the service layer, TypeRefs keep their persisted ids instead of being
coerced to a false File identity, and a truly unidentifiable neighbor
surfaces in an identityErrors entry instead of failing the whole panel.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Aug 24, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
v0-landing-page-build Ready Ready Preview, v0 Aug 24, 2026 1:43am

@Phoenixrr2113
Phoenixrr2113 merged commit 4692feb into main Aug 24, 2026
12 checks passed
@Phoenixrr2113
Phoenixrr2113 deleted the batch-d-file-route-500 branch August 24, 2026 01:48
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