GitNexus/gitnexus/src
Gergo Magyar 62ffee3218 fix(storage): rebuild a shared slot whose graph is missing (#3374)
A publish interrupted between moving the checkout's graph into
`.publish-<uuid>` staging and renaming staging onto the commit dir left
slot metadata at HEAD with no graph and no graphPath; the next reclaim
deleted the orphaned staging. The up-to-date fast path never checked that
the graph exists, so every later analyze reported "Already up to date"
over a checkout with no index. A failed restore in publishSharedGraph's
catch had the same outcome, and also deleted the staging dir holding the
only copy of the graph.

- run-analyze: for a shared-store slot, stat the graph the checkout reads
  (resolveGraphPath for the flat slot, the branch slot's own lbug
  otherwise) before the fast path; if it is missing, force a full
  rebuild. An incremental run would diff nothing into a fresh, empty
  database. Private .gitnexus indexes are unchanged: they only lose their
  graph by hand, and metadata-only fast-path fixtures rely on that path.
- publishSharedGraph: when moving the staged graph back fails and it is
  still in staging, keep the staging dir, log its path, and skip this
  run's reclaim, which would otherwise delete it. The next analyze finds
  no graph and rebuilds.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-25 07:26:12 +00:00
..
cli feat(storage): share the index store between clones automatically (#3352) 2026-09-24 21:43:48 +00:00
config feat(analyze): add incremental watch mode (#3072) 2026-08-29 10:40:56 +00:00
core fix(storage): rebuild a shared slot whose graph is missing (#3374) 2026-09-25 07:26:12 +00:00
lib fix(mcp): stop scaling the detect_changes query with the diff's hunk count (#2915) (#2930) 2026-08-12 14:51:17 +01:00
mcp Merge branch 'main' into feat/shared-sibling-index-store 2026-09-24 17:17:23 +01:00
server feat(storage): share the index store between clones automatically (#3352) 2026-09-24 21:43:48 +00:00
storage fix(storage): never share a graph from a checkout that hides files (#3374) 2026-09-25 06:50:08 +00:00
types fix(resolution): label fallback guesses and preserve export visibility (#3190) 2026-09-10 11:38:19 +01:00
utils perf(lock): probe this process's own start time once (#3222) 2026-09-08 19:06:03 +01:00