MCPcopy Create free account
hub / github.com/cocoindex-io/cocoindex-code / _bg_index

Function _bg_index

src/cocoindex_code/cli.py:1006–1016  ·  view source on GitHub ↗

Index in background. Each call opens its own daemon connection.

(project_root: str)

Source from the content-addressed store, hash-verified

1004
1005
1006async def _bg_index(project_root: str) -> None:
1007 """Index in background. Each call opens its own daemon connection."""
1008 import asyncio
1009
1010 from . import client as _client
1011
1012 loop = asyncio.get_event_loop()
1013 try:
1014 await loop.run_in_executor(None, lambda: _client.index(project_root))
1015 except Exception:
1016 pass
1017
1018
1019# --- Daemon subcommands ---

Callers 2

_run_mcpFunction · 0.85
_serveFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected