devchat-ai / devchat

Automate your dev tasks with AI-powered scripts, from your IDE's chat panel.
https://www.devchat.ai
Apache License 2.0
340 stars 39 forks source link

Duplicate File Indexing in File Index Service #326

Closed yangbobo2021 closed 4 months ago

yangbobo2021 commented 4 months ago

There's an issue within the file indexing service where files are indexed multiple times, which is not the intended behavior. Specifically, when opening a project and viewing the list of indexed files, as the timer triggers a second indexing task, some files still appear in the index list. This redundant indexing could potentially lead to performance issues and inaccuracies in file management.

Steps to Reproduce:

  1. Open a project.
  2. Observe the list of files indexed.
  3. Wait for the indexing timer to trigger a second indexing task.
  4. Notice that some files are indexed again and appear in the list of indexed files.

Expected Behaviour: Files should only be indexed once, and duplicate indexing should be prevented to maintain optimal performance and accuracy.

This issue appears to be a bug in the indexing logic or in the mechanism that detects already indexed files. A fix to prevent files from being indexed multiple times would greatly improve the efficiency and reliability of the file indexing service.