index_repository(async=true): while indexing is queued/running, list_projects returns empty and read tools return misleading "No projects indexed yet. Call index_repository first."
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 50/100
- Issue-Typ
- Bug
- Klarheit
- Klar beschrieben
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- c, sqlite
- Bereich
- backend-api-design
Rechercherichtung
Start by reading the project lookup and error handling at src/mcp/mcp.c:2852, then trace how index_repository records queued and running jobs and how list_projects checks indexed projects. Reproduce with a fresh cache and an asynchronous index job, then check the read tool and project list responses while it runs. Done when they identify indexing as in progress and direct callers to poll status.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Version
codebase-memory-mcp 0.12.1 (built from source at 9a4da7a3; also verified unchanged on main d5e39e5a, src/mcp/mcp.c:2852)
Platform
Linux (x64)
Install channel
Built from source
Binary variant
standard
What happened, and what did you expect?
When index_repository is started with "async": true on a fresh cache directory and is still queued or running:
list_projectsreturnstotal: 0with"hint": "No projects indexed. Call index_repository(repo_path=...) first."without indicating an active indexing job.- Read tools such as
get_graph_schemafail with"error": "project not found or not indexed"and"hint": "No projects indexed yet. Call index_repository first."(src/mcp/mcp.c:2852), even thoughindex_repository(status=true)simultaneously reports the same project asrunning.
Expected: while an async index job for a project is queued or running, read tools (and/or list_projects) should report that indexing is currently in progress and direct callers to poll index_repository(repo_path=..., status=true) instead of claiming no projects have been indexed and telling them to call index_repository again.
Reproduction
- Code: a small synthetic C repository in
/tmp/probe-repo(large enough thatmode: "full"staysqueued/runningfor a moment, e.g., ~200 small.cfiles). - MCP calls on a fresh
CBM_CACHE_DIR:- Call 1 —
list_projects:
Output:{"format": "json"}{"projects":[],"total":0,"offset":0,"limit":50,"returned":0,"has_more":false,"hint":"No projects indexed. Call index_repository(repo_path=...) first."} - Call 2 —
index_repository:
Output:{"repo_path": "/tmp/probe-repo", "name": "probe-async-pre", "mode": "full", "async": true}{"project":"probe-async-pre","state":"queued","async":true,"joined":false,"poll":"call index_repository with the same repo_path and status: true until state is succeeded, failed or cancelled"} - Call 3 (immediately after Call 2) —
get_graph_schema:
Actual output ({"project": "probe-async-pre", "format": "json"}isError: true):{"error":"project not found or not indexed","hint":"No projects indexed yet. Call index_repository first."} - Call 4 (immediately after Call 3) —
index_repository:
Output:{"repo_path": "/tmp/probe-repo", "name": "probe-async-pre", "status": true}{"project":"probe-async-pre","state":"running","async":true,...,"poll":"call again with status: true until state is succeeded, failed or cancelled"}
- Call 1 —
- Expected for Call 3: an in-progress hint (e.g., noting that
"probe-async-pre"is currentlyqueued/runningand suggestingindex_repository(..., status=true)).
Logs
Call 2 response: {"project":"probe-async-pre","state":"queued","async":true,"joined":false,"poll":"call index_repository with the same repo_path and status: true until state is succeeded, failed or cancelled"}
Call 3 response (isError=true): {"error":"project not found or not indexed","hint":"No projects indexed yet. Call index_repository first."}
Call 4 response: {"project":"probe-async-pre","state":"running","async":true,"poll":"call again with status: true until state is succeeded, failed or cancelled"}
Confirmations
- I searched existing issues and this is not a duplicate.
- My reproduction uses shareable code (a dummy snippet or a public OSS repository), not proprietary code.
- Vorherrschende Sprache
- C
- Sterne
- 45.8k
- Forks
- 3.8k
- Ø Merge
- 2 T. 18 Std.
- Gemergte PRs (30 T.)
- 108
Entwicklungsumgebung
Dieses Projekt bietet weder Dev-Container noch Dockerfile noch Beitragsleitfaden – die Einrichtung liegt bei Ihnen. Beginnen Sie mit der README; die allgemeinen Schritte stehen in unserem Leitfaden für den ersten Beitrag.
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus DeusData/codebase-memory-mcp
-
bug ux/behavior
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
DeusData/codebase-memory-mcp#3191 ·
Maintainer antworten meist innerhalb von 1 Tag
-
documentation enhancement parsing/quality ux/behavior
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 82/100
DeusData/codebase-memory-mcp#3131 · 1 Kommentar · 1 Reaktion ·
Maintainer antworten meist innerhalb von 1 Tag
-
hook-augment: the five-row cap keeps the first five search_graph rows, so variables and modules displace function definitions (v0.12.1)Evtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offenbug editor/integration parsing/quality ux/behavior
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
DeusData/codebase-memory-mcp#3062 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug documentation editor/integration parsing/quality
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
DeusData/codebase-memory-mcp#3050 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
editor/integration parsing/quality
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
DeusData/codebase-memory-mcp#2286 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in DeusData/codebase-memory-mcp
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
Maintainer antworten meist innerhalb von 2 Tagen
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 85/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
NVIDIA/open-gpu-kernel-modules#1635 ·
Maintainer antworten meist innerhalb von 1 Tag
-
iOS: the "Edit controls" button never hides, even with a controller connected, and covers the gameOffengame: 010065A014024000 ios
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
seedds/nxnative#3714 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 2 Tagen