Skip to main content
CLI Reference

travsr fsck

Check the graph against itself and against the filesystem, and optionally repair what it finds.

travsr fsck # report only
travsr fsck --fix # repair

What it checks

ProblemMeaning
Ghost pathsIndexed, but the file is gone from disk. Why a query can return a path:line that no longer exists
Orphan edgesAn edge whose endpoint node is missing
Lexical index parityThe full-text index and the node table no longer describe the same set
Self-referential ref/call edgesA symbol recorded as calling itself, which is a defect rather than a curiosity

Options

FlagMeaning
--fixDelete ghost nodes and sweep orphan edges. Default is report only
--jsonMachine-readable output
--forceOverride the mass-delete circuit breaker

--force and the circuit breaker

--fix refuses to proceed when the repair would delete an implausibly large share of the graph. That usually means the working tree is not what the index expects (a branch switch mid-index, a partial checkout, a wrong working directory), and deleting on that basis destroys a good index rather than repairing a bad one.

--force overrides it. Reach for it only once you know why the count is large.

When to run it

  • A result names a file that does not exist.
  • After a large branch switch or rebase that moved many files at once.
  • Before trusting an empty answer: a graph with orphan edges is not evidence of absence.

The report half is available to agents as the get_graph_health MCP tool. --fix is deliberately not exposed over MCP.