fix(discover): deploy/ directories indexed as duplicate source in full mode#448
Open
isc-tdyar wants to merge 1 commit into
Open
fix(discover): deploy/ directories indexed as duplicate source in full mode#448isc-tdyar wants to merge 1 commit into
isc-tdyar wants to merge 1 commit into
Conversation
…l mode
deploy/ and deployed/ build artifact directories were in FAST_SKIP_DIRS,
which only applies in fast/moderate indexing modes. In the default full
mode they were indexed alongside source files, creating duplicate
Class/Method rows with stale data. Any MATCH (c:Class {name:'Foo'})
without a file_path filter returned multiple rows — one from source,
one from the build copy.
Move deploy and deployed to ALWAYS_SKIP_DIRS so they are excluded in all
indexing modes.
Regression test: discover_deploy_excluded_full_mode in test_discover.c.
Signed-off-by: Thomas Dyar <tdyar@intersystems.com>
Owner
|
Thanks for the contribution — all gates are green including DCO, and the deploy/-directory duplication is a good catch. Will review when time allows. |
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.
deploy/ directories indexed as duplicate source in full mode, producing stale duplicate Class/Method rows
Discovered while querying a project that uses a
deploy/directory for build output. Queries likeMATCH (c:Class {name:'Foo'})returned multiple rows for the same class — one from the source file, one from the copy indeploy/.Root cause
deployanddeployedwere inFAST_SKIP_DIRS, which is only consulted infastandmoderateindexing modes. In the defaultfullmode,FAST_SKIP_DIRSis not applied, sodeploy/was walked and indexed alongside source files. Any class that existed in both locations got duplicate rows in the graph with potentially stale data from the build copy.Fix
Move
deployanddeployedfromFAST_SKIP_DIRStoALWAYS_SKIP_DIRSso they are excluded in all indexing modes.Regression test
discover_deploy_excluded_full_modeintests/test_discover.c— creates a temporary repo withsrc/,deploy/, anddeployed/subdirectories, runs discovery in full mode, and asserts only the file undersrc/is returned (deploy and deployed are excluded).