mirror of
https://github.com/abhigyanpatwari/GitNexus.git
synced 2026-10-01 02:01:24 +00:00
* feat(storage): resolve the shared sibling-store identity and layout (#3352) Linked worktrees of one repository resolve to one store under GITNEXUS_HOME/stores/<key>, keyed by the canonical git common dir. The resolver reads the .git entry directly, so hot paths spawn no git. Slot naming moves to a leaf module so storage-resolver and shared-store do not import each other. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(storage): resolve a shared checkout's graph and existing store slot (#3352) getStoragePaths reads a flat slot's recorded graphPath only for checkout slots under the stores directory; other paths keep <storagePath>/lbug with no I/O. A recorded path outside the store's commit graphs is ignored. resolveStoragePath falls back to an existing store slot for an unregistered checkout, so reads never move to an empty slot. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(analyze): share one immutable commit graph across clean worktrees (#3352) A linked worktree writes its own slot in the shared store. A new slot is seeded with a pointer to the nearest commit graph, so a clean checkout at an indexed commit takes the up-to-date path and writes no graph. A checkout with local changes gets a copy-on-write private graph before its first write. After a successful run, a clean checkout at HEAD publishes its graph into commits/ under a store lock, or drops it when that commit graph already exists. Commit graphs are never written after publish. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(analyze): seed a worktree's graph from the nearest index (#3352) A new shared slot is seeded from the store's commit graph nearest to HEAD, else from this checkout's or the main checkout's repository-local index (copied under that index's lock, source left in place). The run that follows is up to date or incremental instead of a full build. If a pointed-at shared graph has been removed, analyze falls back to a full build instead of an incremental update over a missing baseline. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(analyze): keep one parse cache per shared store (#3352) Linked worktrees read and write the parse cache and durable ParsedFile store under the store's caches/ directory. Before pruning, a run folds in the chunk keys recorded by every member slot and commit graph, and the fold, prune and save run under a store-wide cache lock so one member never evicts another's live chunks. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(clean): remove only what no shared-store member references (#3352) Deleting a shared checkout slot (clean, clean --all, remove, and the server delete route) recounts references under the store's publish lock and deletes commit graphs no member points at, then the store itself once empty. A graph that cannot be deleted (open on Windows) is reported and kept for the next pass. clean --gc also drops member slots whose worktree is gone or no longer resolves to the store. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(analyze): let a clone opt in to a shared store with --share-with (#3352) An independent clone joins a linked worktree's shared store only with analyze --share-with <repo>, and only when its normalized origin URL matches that member's (credentials stripped, as #2054 compares). The registry remembers the choice. --no-share moves an opted-in clone back to its own .gitnexus and reclaims its old slot; linked worktrees always share and are pointed at GITNEXUS_SHARED_STORE=off instead. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): count a shared checkout's commit graph as its code index (#3352) A clean shared checkout reads a commit graph and owns no graph file, so the code-index presence check made status report it unindexed and registry validation skip it. The check now follows the slot's validated graphPath. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(storage): adopt existing worktree indexes and report shared-store state (#3352) A shared checkout gets <repo>/.gitnexus/store.json pointing at its store slot; resolution follows it only when it names that checkout's own slot. An existing local index seeds the slot and is left in place. status (text and --json) and doctor report the store, whether the graph is shared or private, and any leftover local index, which clean --local-index removes while keeping the pointer. With GITNEXUS_SHARED_STORE=off a previously shared checkout indexes into its own .gitnexus again and never writes a commit graph. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * feat(mcp): read the graph a shared checkout points at (#3352) MCP, the HTTP API, group sync, augmentation, and the Claude hook (all three byte-identical copies) resolve a flat slot's graph through resolveGraphPath instead of joining 'lbug' onto the storage path, so checkouts at one commit share one open database. The embeddings writers (embeddings sync and the server embed job) take a private copy first and never write an immutable commit graph. The post-analyze settle probe accepts fresh metadata that points at an existing commit graph. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * docs: describe the shared worktree index store (#3352) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * refactor(storage): reuse helpers across the shared-store code (#3352) One graph-clone helper replaces two copy-then-rename blocks; clean and status reuse formatSlotSize; leaving a store reuses removeSharedStorePointer; withStoreLock is imported from its own module instead of a re-export. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): address review findings in the shared store (#3352) - Never publish a graph whose build saw dirty files, and never trust a local-index seed on the up-to-date path; it may hold reverted edits. - Record slot pointers and reclaim under the publish lock, and reclaim right after each publish, so a commit graph is never deleted between publish and pointer save and superseded graphs don't pile up. - clean --gc decides membership from the registry, so opted-in clones and a main checkout without worktrees are not dropped. - Leaving a store re-registers first, so an up-to-date run cannot leave the registry pointing at a deleted slot. - Drop pinned branch summaries when an entry moves into a store slot. - Keep run.cjs and the AGENTS.md runner path inside the checkout. - MCP handles follow the slot's current graph, and branch scoping reads the slot's own metadata. - Cache resolveGraphPath by metadata file identity; look up opted-in entries with canonical registry paths. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(cli): localize help for the shared-store flags (#3352) --help renders option text from the i18n catalog, so --share-with, --no-share, clean --gc and clean --local-index need keys in both locales, not just index.ts literals. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): lock the embed-job graph copy and skip it on forced rebuilds (#3352) The server embed job copies a shared checkout's graph under the slot's index lock, so a CLI analyze in another process cannot interleave. A forced rebuild with no embeddings to carry over drops the pointer without copying a graph it would discard unread. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * docs(agents): bump AGENTS.md version for the shared store notes (#3352) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): keep shared-store file reads inside checked paths (#3374) Address CodeQL js/path-injection and js/file-system-race on shared-store.ts: every filesystem read rebuilds its path under a fixed parent with an inline path.relative barrier, the .git probe is one read (EISDIR marks a directory) instead of stat-then-read, and the graph pointer cache stats and reads through one file descriptor. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): address review feedback on the shared store (#3374) - Hold the slot index lock for the whole server embedding job, not just the graph copy. - --no-share re-registers and deletes the old slot under that slot's index lock, so a running shared analyze cannot re-register it. - clean --gc previews without --force, like every other destructive arm. - status reports a pinned branch index as private. - Slot names prefix Windows device names that carry an extension. - A slot or store named ..<name> is a legal direct child. - Shared-store suites run in the serialized lbug-db vitest project and clear an inherited GITNEXUS_SHARED_STORE. - Doc and test accuracy fixes. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * test(storage): pin shared-store behavior for worktrees of a bare repository (#3374) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): address second review round on the shared store (#3374) - Reject --no-share in a linked worktree before taking any lock or indexing anything. - clean --all and remove also delete each shared checkout's pointer. - Delete an empty store only while also holding its cache lock, and re-check emptiness under it. - A store pointer is trusted only when the slot's own metadata names this checkout; the editable pointer file just says where to look. - Device names with an extension are prefixed on Windows only, so POSIX slot names stay stable. - Test fixtures use the gitnexus-test- prefix the stale-sidecar sweep recognizes; help text and the private-graph label are accurate. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(storage): address third review round on the shared store (#3374) - clean --gc never collects a slot whose index lock is held: an analyze holds it until it registers the checkout, so a seeded but not yet registered slot is busy, not orphaned. - Reclaim compares absolute paths, so a relative GITNEXUS_HOME does not make live commit graphs look unreferenced. - graphPath is followed only into a published <commit>-<featureKey> dir, never .publish-* staging (TS and all three hook copies). - clean --gc fails on an unreadable stores root instead of reporting nothing to collect. - --no-share help states it is for opted-in clones. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> * fix(cli): land the English --no-share help and private-graph label (#3374) These two strings were meant for |
||
|---|---|---|
| .. | ||
| cfg | ||
| cli | ||
| group | ||
| mcp | ||
| optional-grammars | ||
| resolvers | ||
| analyze-atomic-swap.test.ts | ||
| analyze-embedding-flags-e2e.test.ts | ||
| analyze-heap-oom-e2e.test.ts | ||
| analyze-index-lock-concurrency.test.ts | ||
| analyze-wal-checkpoint-failure.test.ts | ||
| analyzer-identity-cli.test.ts | ||
| antigravity-hook-e2e.test.ts | ||
| api-impact-e2e.test.ts | ||
| api-impact-method-e2e.test.ts | ||
| api-query.test.ts | ||
| ast-helpers-object-literal-binding.test.ts | ||
| augmentation.test.ts | ||
| basicblock-roundtrip.test.ts | ||
| block-scope-shadowing.test.ts | ||
| c-cpp-typedef-legacy-parse.test.ts | ||
| callable-capture-options-literal-gate.test.ts | ||
| caller-identity-regression.test.ts | ||
| cjs-exports-assignment.test.ts | ||
| class-impact-all-languages.test.ts | ||
| clean-stale-branch-slots.test.ts | ||
| cli-e2e.test.ts | ||
| cli-limit-e2e.test.ts | ||
| closure-binding-labels.test.ts | ||
| closure-review-findings.test.ts | ||
| cobol-import-index-reuse.test.ts | ||
| cobol-pipeline-benchmark.test.ts | ||
| const-function-twin.test.ts | ||
| context-cross-language-anchor.test.ts | ||
| context-resource-staleness.test.ts | ||
| context-typed-property.test.ts | ||
| convex-impact-epistemic-e2e.test.ts | ||
| copy-parallel-invariant.test.ts | ||
| cpp-adl-benchmark.test.ts | ||
| cpp-captures-typeclass-benchmark.test.ts | ||
| cpp-pipeline-benchmark.test.ts | ||
| cross-file-binding.test.ts | ||
| csharp-import-index-reuse.test.ts | ||
| csharp-pipeline-benchmark.test.ts | ||
| csharp-razor-view-components-benchmark.test.ts | ||
| csharp-razor-view-components.test.ts | ||
| csharp-scope-capture-tripwire.test.ts | ||
| csv-pipeline.test.ts | ||
| dart-import-index-reuse.test.ts | ||
| data-route-table-benchmark.test.ts | ||
| data-route-table-pipeline.test.ts | ||
| detect-changes-path-anchoring.test.ts | ||
| dispatch-guard-route-pipeline.test.ts | ||
| django-route-extraction-e2e.test.ts | ||
| doc-comment-description-e2e.test.ts | ||
| enrichment.test.ts | ||
| expo-routes.test.ts | ||
| extension-binary-real.test.ts | ||
| external-storage-content-retention.test.ts | ||
| fastapi-composed-route-constants.test.ts | ||
| fastapi-prefix-pipeline.test.ts | ||
| filesystem-walker.test.ts | ||
| fts-cjk-segmentation-search.test.ts | ||
| fts-description-search.test.ts | ||
| fts-extension-e2e.test.ts | ||
| fts-fullfile-search.test.ts | ||
| fts-repair-warm-session.test.ts | ||
| fts-stemmer-sweep.test.ts | ||
| fts-vendored-root-seam.test.ts | ||
| fts-windows-dependency.test.ts | ||
| function-local-identity.test.ts | ||
| go-import-index-reuse.test.ts | ||
| go-multi-name-worker-metadata.test.ts | ||
| go-pipeline-benchmark.test.ts | ||
| grammar-introspection.test.ts | ||
| grammar-literal-validation.test.ts | ||
| graph-emit-streaming-roundtrip.test.ts | ||
| has-method.test.ts | ||
| hooks-e2e.test.ts | ||
| http-inline-handler-symbol-roundtrip.test.ts | ||
| ignore-and-skip-e2e.test.ts | ||
| impact-ambiguous-blast-radius.test.ts | ||
| impact-callable-value-references.test.ts | ||
| impact-epistemic-lower-bound.test.ts | ||
| impact-file-risk-scale.test.ts | ||
| impact-pdg-callsummary-degradation.test.ts | ||
| impact-pdg-degradation.test.ts | ||
| impact-pdg-e2e.test.ts | ||
| impact-pdg-fixtures.test.ts | ||
| impact-pdg-fullchain-e2e.test.ts | ||
| impact-pdg-id-degradation.test.ts | ||
| impact-pdg-interproc.test.ts | ||
| impact-pdg-shape.test.ts | ||
| impact-pdg-statement-precise.test.ts | ||
| impact-pdg-traversal.test.ts | ||
| impact-scope-omission-persistence.test.ts | ||
| impact-undecided-satisfaction.test.ts | ||
| impact-zero-caller-risk.test.ts | ||
| instance-ownership-pipeline-benchmark.test.ts | ||
| java-class-impact.test.ts | ||
| js-array-method-callback-attribution.test.ts | ||
| kotlin-spring-route-pipeline.test.ts | ||
| lbug-close-handle-release.test.ts | ||
| lbug-conn-serialization.test.ts | ||
| lbug-core-adapter.test.ts | ||
| lbug-delete-nodes-for-files.test.ts | ||
| lbug-interrupted-checkpoint-recovery.test.ts | ||
| lbug-load-overlap-errors.test.ts | ||
| lbug-load-overlap.test.ts | ||
| lbug-load-prof.test.ts | ||
| lbug-lock-retry.test.ts | ||
| lbug-multiwriter-deadlock.test.ts | ||
| lbug-non-ascii-path.test.ts | ||
| lbug-open-retry.test.ts | ||
| lbug-orphan-sidecar-recovery.test.ts | ||
| lbug-pool-stability.test.ts | ||
| lbug-pool.test.ts | ||
| lbug-query-importers-batch.test.ts | ||
| lbug-readonly-init.test.ts | ||
| lbug-vector-extension.test.ts | ||
| literal-collectors.test.ts | ||
| load-cached-embeddings-spill.test.ts | ||
| local-backend-calltool.test.ts | ||
| local-backend.test.ts | ||
| local-symbol-pruner-pipeline.test.ts | ||
| markdown-processor-crlf.test.ts | ||
| mcp-line-display.test.ts | ||
| multi-branch-analyze.test.ts | ||
| multi-verb-route-identity.test.ts | ||
| nest-route-pipeline.test.ts | ||
| object-literal-impact.test.ts | ||
| object-literal-method-exports.test.ts | ||
| object-literal-owner-resolution.test.ts | ||
| objective-c-pipeline-benchmark.test.ts | ||
| objective-c-provider.test.ts | ||
| orm-dataflow.test.ts | ||
| parse-impl-chunk-concurrency.test.ts | ||
| parse-impl-clone-skip.test.ts | ||
| parse-impl-dispatch-rounds.test.ts | ||
| parse-impl-env-reads.test.ts | ||
| parse-impl-large-fixture.test.ts | ||
| parse-impl-progress-monotonic.test.ts | ||
| parse-impl-quarantine-cache-skip.test.ts | ||
| parsing.test.ts | ||
| pdg-emit-streaming-roundtrip.test.ts | ||
| pdg-query.test.ts | ||
| php-import-index-reuse.test.ts | ||
| php-pipeline-benchmark.test.ts | ||
| php-scope-capture-tripwire.test.ts | ||
| pipeline-graph-golden.test.ts | ||
| pipeline.test.ts | ||
| python-import-index-reuse.test.ts | ||
| python-scope-capture-tripwire.test.ts | ||
| qualified-class-lookups.test.ts | ||
| query-compilation.test.ts | ||
| route-handler-symbol-roundtrip.test.ts | ||
| route-method-roundtrip.test.ts | ||
| route-parse-skip.test.ts | ||
| route-runtime-evidence-roundtrip.test.ts | ||
| ruby-import-index-reuse.test.ts | ||
| ruby-pipeline-benchmark.test.ts | ||
| ruby-scope-capture-tripwire.test.ts | ||
| run-analyze-adopt-failure.test.ts | ||
| run-analyze-invalidates-workspace-memo.test.ts | ||
| rust-pipeline-benchmark.test.ts | ||
| rust-scope-capture-tripwire.test.ts | ||
| search-core.test.ts | ||
| search-pool.test.ts | ||
| server-analyze-branch-validation.test.ts | ||
| server-analyze-token-validation.test.ts | ||
| server-analyze.test.ts | ||
| server-http-startup.test.ts | ||
| server-repo-freshness.test.ts | ||
| setup-antigravity.test.ts | ||
| setup-skills.test.ts | ||
| setup-uninstall-roundtrip.test.ts | ||
| shape-check-regression.test.ts | ||
| shared-store-adoption.test.ts | ||
| shared-store-analyze.test.ts | ||
| shared-store-cache.test.ts | ||
| shared-store-clean.test.ts | ||
| shared-store-clone-optin.test.ts | ||
| shared-store-seed.test.ts | ||
| skills-e2e.test.ts | ||
| skip-fts.test.ts | ||
| spring-actuator-kotlin-runtime-pipeline.test.ts | ||
| spring-actuator-runtime-pipeline.test.ts | ||
| spring-aop-benchmark.test.ts | ||
| spring-aop-mcp.test.ts | ||
| spring-aop-pipeline.test.ts | ||
| spring-bean-mcp.test.ts | ||
| spring-bean-metadata-roundtrip.test.ts | ||
| spring-bean-pipeline.test.ts | ||
| spring-bean-resource-benchmark.test.ts | ||
| spring-bean-resource-pipeline.test.ts | ||
| spring-conditionals-pipeline.test.ts | ||
| spring-config-mcp.test.ts | ||
| spring-config-pipeline.test.ts | ||
| spring-constructor-bean-roundtrip.test.ts | ||
| spring-destinations-incremental.test.ts | ||
| spring-destinations-lbug.test.ts | ||
| spring-destinations-pipeline.test.ts | ||
| spring-di-benchmark.test.ts | ||
| spring-di-pipeline.test.ts | ||
| spring-dynamic-lookup-benchmark.test.ts | ||
| spring-dynamic-lookup.test.ts | ||
| spring-inheritance-benchmark.test.ts | ||
| spring-interface-inheritance-pipeline.test.ts | ||
| spring-non-http-handlers-pipeline.test.ts | ||
| spring-route-pipeline.test.ts | ||
| staleness-and-stability.test.ts | ||
| structural-pair-coverage.test.ts | ||
| swift-conditional-directive.test.ts | ||
| swift-scope-capture-tripwire.test.ts | ||
| taint-explain.test.ts | ||
| this-boundary.test.ts | ||
| tree-sitter-languages.test.ts | ||
| typescript-async-generator-functions.test.ts | ||
| vue-pipeline-benchmark.test.ts | ||
| watch-filesystem.test.ts | ||
| wiki-graph-queries-engine.test.ts | ||
| worker-pool.test.ts | ||