dmtrKovalenko/fff · warning
Git repository: not found (fff-mcp will still work, but…
Error message
Git repository: not found (fff-mcp will still work, but git-status features are disabled)
What it means
The fff-mcp healthcheck could not detect a git repository in the current working directory. This is a non-fatal warning: the MCP server runs fine, but git-status-based features (e.g. showing modified/untracked flags) are disabled. It is informational output from the doctor/healthcheck command, not a thrown exception.
Solutions
- Run the server from inside a git repository (cd into the project) or configure the working directory to a repo path.
- Clone the project with git rather than extracting an archive so .git exists.
- Check filesystem permissions on .git if the directory should be a repo.
- Ignore the warning if git-status features are not needed — the healthcheck marks it non-fatal.
Example fix
// before // launching from a non-repo dir exec: fff-mcp serve cwd: /tmp // after exec: fff-mcp serve cwd: /home/user/my-project # a git repository
Defensive patterns
Strategy: fallback
Validate before calling
// before starting the server
const inRepo = spawnSync('git', ['rev-parse', '--is-inside-work-tree'], { cwd }).status === 0;
if (!inRepo) console.warn('git-status features disabled: not a git repository'); Try / catch
// healthcheck output is advisory; degrade gracefully
if (!inGitRepo) {
disableGitStatusFeatures();
logger.warn('git-status features disabled: not a git repository');
} Prevention
- Launch fff-mcp with cwd set to a git repository.
- Clone repos with git instead of downloading archives in CI.
- Verify .git readability when running in restricted environments.
- Treat this healthcheck line as informational, not fatal.
When it happens
Trigger: Running the fff-mcp healthcheck (run_healthcheck) in a directory that is not inside a git worktree (git detection returned Err) — e.g. a bare parent checkout, $HOME outside any repo, or a directory where git metadata is inaccessible.
Common situations: Starting the MCP server from a non-repo directory like /tmp or $HOME; running in CI where the repo was downloaded as a tarball without .git; restricted environments where .git is unreadable; intending bare-repo support but cwd points elsewhere.
AI-assisted analysis of dmtrKovalenko/fff@7f8537e70f (2026-09-10).
Data as JSON: /api/errors/88839c39147f9aea.
Report an issue: GitHub.
Appendix: source
Thrown at crates/fff-mcp/src/healthcheck.rs:50
if path_exists {
&base_path
} else {
"directory does not exist"
},
);
// 2. Git repository
match Repository::discover(&base_path) {
Ok(repo) => {
if let Some(workdir) = repo.workdir() {
all_ok &= check("Git repository", true, &format!("{}", workdir.display()));
} else {
all_ok &= check("Git repository", true, "bare repository");
}
}
Err(_) => {
// Not fatal — fff-mcp works without git, but worth flagging.
warn(
"Git repository",
"not found (fff-mcp will still work, but git-status features are disabled)",
);
}
}
// 3. Frecency database
if let Some(ref db_path) = args.frecency_db_path {
let parent_ok = std::path::Path::new(db_path)
.parent()
.is_some_and(|p| p.is_dir());
all_ok &= check(
"Frecency DB",
parent_ok,
if parent_ok {
db_path
} else {
"parent directory does not exist"View on GitHub (pinned to 7f8537e70f)