Bug Description
When running grepai watch on a large repository and stopping with Ctrl-C (the documented stop method), the shutdown process exceeds an internal timeout, resulting in a partially-written gob index file that cannot be loaded on next startup.
Steps to Reproduce
Steps to reproduce:
Run grepai index on a large repository (openclaw codebase, ~hundreds of files)
Run grepai watch — wait for Watching for changes... (Press Ctrl+C to stop)
Press Ctrl-C to stop
Observe shutdown output shows [STOPPED] - shutdown timeout
Run grepai watch again
Expected Behavior
Watch stops cleanly and the index is intact on next run.
Actual Behavior
[STOPPED] C:\development\ai\openclaw-code\openclaw - shutdown timeout
On next grepai watch:
[ERROR] C:\development\ai\openclaw-code\openclaw - failed to load index: failed to decode index: unexpected EOF
Error: failed to load index: failed to decode index: unexpected EOF
grepai Version
grepai version 0.35.0
Operating System
Windows
Embedding Provider
Ollama (nomic-embed-text)
Relevant Logs
Configuration
Checklist
Bug Description
When running grepai watch on a large repository and stopping with Ctrl-C (the documented stop method), the shutdown process exceeds an internal timeout, resulting in a partially-written gob index file that cannot be loaded on next startup.
Steps to Reproduce
Steps to reproduce:
Run grepai index on a large repository (openclaw codebase, ~hundreds of files)
Run grepai watch — wait for Watching for changes... (Press Ctrl+C to stop)
Press Ctrl-C to stop
Observe shutdown output shows [STOPPED] - shutdown timeout
Run grepai watch again
Expected Behavior
Watch stops cleanly and the index is intact on next run.
Actual Behavior
[STOPPED] C:\development\ai\openclaw-code\openclaw - shutdown timeout
On next grepai watch:
[ERROR] C:\development\ai\openclaw-code\openclaw - failed to load index: failed to decode index: unexpected EOF
Error: failed to load index: failed to decode index: unexpected EOF
grepai Version
grepai version 0.35.0
Operating System
Windows
Embedding Provider
Ollama (nomic-embed-text)
Relevant Logs
Configuration
Checklist