The optional native graph-acceleration provider exposes `isInitialized`, which is false during its cold-start / rebuild window (engine + cursor not yet loaded). The accessor cached the resolved provider INSTANCE but never re-checked readiness, so `brain.graph.*` could dispatch to a not-ready provider and throw instead of answering. Resolve and cache the instance once, but check `isInitialized` LIVE on every call: route to the pure-TS analytics path while the provider is not ready, and re-engage the native path automatically the moment it flips true. This gates every native route at once — subgraph, export, rank, communities, path, and the query→expand fusion. Adds a test asserting the provider is never called (and the TS fallback returns real answers) while not ready. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| add.test.ts | ||
| batch-operations.test.ts | ||
| counts-by-type-fix.test.ts | ||
| fill-subtypes.test.ts | ||
| find-agg-edge-cases.test.ts | ||
| find-include-vectors.test.ts | ||
| find-orderby-pagek.test.ts | ||
| find.test.ts | ||
| get.test.ts | ||
| graph-analytics.test.ts | ||
| graph-export.test.ts | ||
| graph-native-routing.test.ts | ||
| graph-subgraph.test.ts | ||
| hybrid-search.test.ts | ||
| relate-duplicate-optimization.test.ts | ||
| relate.test.ts | ||
| related-node-bidirectional.test.ts | ||
| related-visibility-fast-path.test.ts | ||
| reserved-field-policy.test.ts | ||
| similar-threshold.test.ts | ||
| update-reserved-metadata-remap.test.ts | ||
| update.test.ts | ||
| upsert.test.ts | ||
| visibility.test.ts | ||