Fix symlinked gitignored paths in code review#11856
Merged
MaggieShan merged 7 commits intoJun 2, 2026
Merged
Conversation
Contributor
|
I'm starting a first review of this pull request. You can view the conversation on Warp. I completed the review and no human review was requested for this pull request. Comment Powered by Oz |
Contributor
There was a problem hiding this comment.
Overview
This PR threads gitignore information into the repository DirectoryWatcher filter so recursive watches can prune ignored directories such as node_modules, while keeping the local repo metadata watcher on the previous unpruned behavior.
Concerns
- The new gitignore filtering is also applied to
.git/paths after the existing allowlist, so repo/global ignore patterns can suppress the git-internal events this watcher must preserve. - No approved spec context was available for this PR, and I found no separate security findings.
Verdict
Found: 0 critical, 1 important, 0 suggestions
Request changes
Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).
Powered by Oz
Reverts LRMM to use repo_watch_filter without gitignore pruning so the file tree UI continues to receive real-time updates for files inside gitignored directories (e.g. expanded node_modules/). The .git/ allowlist still applies via the empty-gitignore variant. Only DirectoryWatcher (which feeds code review / Repository subscribers) needs the gitignore-aware filter to prevent cross-repo events from pnpm symlinks. Co-Authored-By: Oz <oz-agent@warp.dev>
d44c060 to
45e8736
Compare
kevinyang372
reviewed
Jun 1, 2026
kevinyang372
approved these changes
Jun 2, 2026
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.
Description
Git command failed: fatal: <path>/node_modules/<path>' is outside repository)As per oz's investigation https://staging.warp.dev/conversation/e7f00920-692d-4314-86e3-adcb65c11ff9TheDirectoryWatcher's file watcher is registering gitignored directories likenode_moduleswhich follows its symlink entries and ends up registering paths outside the active repo => this means that we'd receive file watcher events for these file changes and fail to run commands likegit diff -- <file>node_moduleswe weren't correctly attributing the file paths to their correct repositories which resulted in an inaccurateis_ignoredvalueis_ignoredsuch that we're checking for the non-canonicalized paths which don't follow the symlinksLinked Issue
APP-4632
Testing
./script/runAgent Mode