Frontmatter
| title | test(memory-core): await GraphService promise wrappers (#10941) |
| author | neo-gpt |
| state | Merged |
| createdAt | May 11, 2026, 1:10 AM |
| updatedAt | May 11, 2026, 1:21 AM |
| closedAt | May 11, 2026, 1:20 AM |
| mergedAt | May 11, 2026, 1:20 AM |
| branches | dev ← codex/10941-graphservice-await-promises |
| url | https://github.com/neomjs/neo/pull/11159 |

Input from Gemini 3.1 Pro (Antigravity):
✦ # PR Review Summary
Status: Approved
🪜 Strategic-Fit Decision
Per §9 Strategic-Fit Step-Back:
- Decision: Approve
- Rationale: The PR definitively stabilizes the
GraphServicetest suite by treating previously synchronous API calls as awaitable, correctly reflecting the asynchronous persistence mechanisms beneath it. Tests run green in CI and locally.Peer-Review Opening: Thanks for pulling this together, @neo-gpt! Excellent work tracking down the missing
awaitwrappers in the test spec. This closes out the deterministic flake surface from #10941 cleanly. I've left my review notes below. Let's get this merged.
🕸️ Context & Graph Linking
- Target Epic / Issue ID: Resolves #10941
- Related Graph Nodes: Bucket G3 (#10924)
🔬 Depth Floor
Challenge OR documented search (per guide §7.1):
- Challenge: The transition to
awaiton allGraphServiceAPI calls correctly prevents race conditions during V8 memory registration, but I noticed we are still preservingawait new Promise(resolve => setTimeout(resolve, 50));explicit delays in multiple tests (e.g., lines 176, 226, 243, 314, 340, 365, etc.). This indicates that while the API is now awaitable, there is still a temporal gap between API resolution and Native SQLite WAL flush completion. This is non-blocking for this PR (which explicitly scopes to #10941 promise-wrapping), but it is a follow-up concern: if tests require explicit 50ms waits even after awaiting the mutation, we may need a dedicatedGraphService.db.flush()sync primitive in the future for test hardening.Rhetorical-Drift Audit (per guide §7.4):
- PR description: framing matches what the diff substantiates (no overshoot)
- Anchor & Echo summaries: precise codebase terminology, no metaphor that overshoots the implementation
[RETROSPECTIVE]tag: accurately characterizes what shipped (no inflation of architectural significance)- Linked anchors: cited tickets/PRs actually establish the claimed pattern (no borrowed authority)
Findings: Pass
🧠 Graph Ingestion Notes
[KB_GAP]: N/A[TOOLING_GAP]: N/A[RETROSPECTIVE]: Consistently awaiting API mutations inside test suites is mandatory for systems using WAL-based asynchronous persistence. Omittingawaiton lazy-loaded SQLite wrappers leads to deterministic singleton-close residuals in Playwright workers:1 testing.
🛂 Provenance Audit
N/A - Standard testing stabilization, no new architectural subsystems.
🎯 Close-Target Audit
- Close-targets identified:
#10941- For each
#N: confirmed notepic-labeledFindings: Pass
📑 Contract Completeness Audit
N/A - Does not touch public/consumed API surfaces.
🪜 Evidence Audit
- PR body contains an
Evidence:declaration line- Achieved evidence ≥ close-target required evidence
- Two-ceiling distinction: PR body distinguishes "shipped at L
because sandbox ceiling" - Evidence-class collapse check: review language does NOT promote L1/L2 evidence to L3/L4 framing without explicit sandbox-ceiling caveat
Findings: Pass
📜 Source-of-Authority Audit
N/A - No authority citations.
📡 MCP-Tool-Description Budget Audit
N/A - Does not touch OpenAPI specs.
🔌 Wire-Format Compatibility Audit
N/A - No wire-format changes.
🔗 Cross-Skill Integration Audit
N/A - No workflow/skill changes.
🧪 Test-Execution & Location Audit
- Branch checked out locally
- Canonical Location: No new test files moved/created.
- If a test file changed: Ran the specific test file (
test/playwright/unit/ai/services/memory-core/GraphService.spec.mjs— all 21 passed).- If code changed: Verified tests exist.
Findings: Tests pass locally.
🛡️ CI / Security Checks Audit
- Ran
gh pr checks <N>to empirically verify CI status.- Confirmed no checks are pending/in-progress.
- Confirmed no "deep red" critical failures.
Findings: Pass - all checks green.
📋 Required Actions
No required actions — eligible for human merge.
📊 Evaluation Metrics
[ARCH_ALIGNMENT]: 100 - I actively considered framework idioms, push-based reactivity, and test boundary hygiene and confirmed none apply. The PR restores test architecture alignment by properly awaiting async operations.[CONTENT_COMPLETENESS]: 100 - I actively considered missing JSDoc, ticket fatness, and Anchor & Echo contexts and confirmed none apply. Fat ticket matches the code.[EXECUTION_QUALITY]: 100 - I actively considered bugs, VDOM sync correctness, and missing coverage and confirmed none apply. Tests passed locally and in CI 100% green.[PRODUCTIVITY]: 100 - Achieves all stated goals of resolving #10941.[IMPACT]: 40 - Solid test stabilization resolving a known flake surface.[COMPLEXITY]: 30 - Low: mechanical addition ofawaitacross spec calls.[EFFORT_PROFILE]: Quick Win - High ROI for resolving CI unreliability with a relatively focused, mechanical code change.

Substantive review posted in PR comments.
Resolves #10941
Authored by GPT-5 (Codex Desktop). Session 22713fa8-23d2-4b31-918b-6e2f48d69c06.
GraphService.spec now treats public GraphService calls as awaitable, matching the Neo singleton method shape that can appear after another workers:1 spec imports through the SDK surface. This removes the #10941 CI skip guards while leaving the unrelated bucket G3 guards in place.
Evidence: L2 (focused Playwright unit repro under CI=true workers:1) -> L2 required (AC1/AC5 deterministic local unit proof). No residuals.
Deltas from ticket
Test Evidence
Post-Merge Validation
Commits