* The current revision, or null when there is no readable index. * * A missing index is not an error here: `codegraph ui` refuses to start * without one, but a user can delete `.codegraph/` with the viewer open, and * every endpoint already says so in its own words when asked.
()
| 469 | * every endpoint already says so in its own words when asked. |
| 470 | */ |
| 471 | private probe(): WireIndexRevision | null { |
| 472 | try { |
| 473 | const cg: CodeGraph = this.session.acquire(); |
| 474 | const revision = cg.getIndexRevision(); |
| 475 | return { lastIndexedAt: revision.lastIndexedAt, files: revision.fileCount }; |
| 476 | } catch { |
| 477 | return null; |
| 478 | } |
| 479 | } |
| 480 | } |
no test coverage detected