ISS-10889: index every tracked file in a supported language; skip-list directories judge only untracked files - #34
Merged
Conversation
…ped-directory list judges only untracked files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements ISS-10889.
What changes
A file git tracks, in a supported language, is now always indexed. The built-in directory-name skip list (
node_modules,.venv,dist,build,data,results, …) applies only to files git does not track: untracked-but-not-ignored files, and every file in the non-git fallback walk.Before, the skip list matched any path segment at any depth, tracked or not, so real source under a directory that happened to be called
build,dataorresultswas never indexed and never found by search,relations,code_queryorcode_changes.Why
Tracking a file is the owner's statement that it belongs to the project. The name list only earns its place where git gives no signal: a repo that forgot to ignore
.venvornode_modulesmust not flood the index with untracked dependency files.Rules after this change
.lemoncrow/.ignore.lemoncrow/.ignorestill binds tracked files: it is an explicit, user-written opt-out, and the CLI docs already describe it as the way to keep tracked data files out of the index.Where
inclusion.py: newgit_tracked(root, candidates)(literal pathspecs soapp/[id]/page.tsxis not a glob; submodules included; chunked at 1000 paths per call; fails open to "untracked", which applies the full rule list).exclusion_ruletakes a requiredtrackedset and skips the directory rung for tracked paths.indexable_paths(the per-edit re-index) asks git once per batch.graph.py: the whole-repo scan keeps whichls-filescall listed each entry and applies the skip list only to the--othershalf.coverage.py:code_coverage_checknames rules with the same tracked set, so it agrees with both entry points.engine.py: repo-scope symbol search no longer drops indexed hits by directory name (the index's admission rules are the only gate). Commit-history and external-scope hits keep the existing filter.docs/reference/cli.md: describes the tracked/untracked split.Verification
.lemoncrow/.ignorestill binding a tracked file, repo search returning a trackedbuild/symbol, andgit_tracked(literal brackets, submodules, at and past the chunk size, non-git fallback). Every new behavior test fails onmain; the search test also fails with only the query-time filter reverted.iter_source_files, nothing dropped in either):build/,data/andresults/that was missing.benchmarks/codebench/results/.../graft.json.test_index_pool_does_not_fork_live_parent_statefails identically onmainon this machine (spawnvsforkserverstart method), so it is unrelated.