Skip to content

[BUG] Local Mode Watcher Doesn't Re-index Files #153

@olddev94

Description

@olddev94

Project

vgrep

Description

The file watcher in Local mode doesn't actually re-index files when they change. While the initial index_all() works correctly, the process_files() function called for file changes only prints "(pending)" but never actually re-indexes the files. This makes the watcher essentially useless in Local mode.

Error Message

No error - just silently doesn't work.

Debug Logs

System Information

- Bounty Version: 0.1.0
- OS: Ubuntu 24.04 LTS
- Rust: 1.75+

Screenshots

No response

Steps to Reproduce

  1. Configure vgrep for local mode: vgrep config set mode local
  2. Start the watcher: vgrep watch
  3. Initial indexing completes successfully
  4. Modify a file in the watched directory
  5. Observe the watcher prints [~] modified filename.rs (pending)
  6. The file is NEVER actually re-indexed
  7. Search results remain stale

Expected Behavior

In Local mode, file changes should be indexed using the local embedding engine, similar to how Server mode uses index_file_server().

Actual Behavior

  1. Initial index_all() works correctly for Local mode
  2. process_files() only prints "(pending)" for Local mode
  3. Files are never re-indexed after changes
  4. Search results become stale and outdated
  5. The "(pending)" message implies future action that never happens

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingvalidValid issuevgrep

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions