Index in background. Each call opens its own daemon connection.
(project_root: str)
| 1004 | |
| 1005 | |
| 1006 | async 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 --- |