Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't send file change notifications for excluded files #11493

Closed
wants to merge 1 commit into from

Conversation

bobbrow
Copy link
Member

@bobbrow bobbrow commented Oct 2, 2023

I recently noticed a lot of cpptools/fileChanged notifications for files in the .git folder. To reduce the noise, I'm filtering out those files that we're treating as excluded.

@bobbrow bobbrow requested a review from a team October 2, 2023 23:42
@sean-mcmanus
Copy link
Collaborator

The processing is already excluded in cpptools -- it's just logging you're seeing. Are you sure you want this change?

@sean-mcmanus
Copy link
Collaborator

The pattern matching code on the cpptools side doesn't exactly match the one you're using here.

@sean-mcmanus
Copy link
Collaborator

I think the LSP handler in cpptools could be changed to not log for those messges and logging could be added when the file isn't excluded. That seems like a better fix to me.

@bobbrow
Copy link
Member Author

bobbrow commented Oct 3, 2023

It hadn't occurred to me that the exclusions were happening on the native side because it was logging those messages and that made me think the filtering wasn't happening. Yeah, perhaps if those messages could be suppressed from that side we wouldn't need this. We'd have to introduce a new way to filter the logging based on some processing though since right now it just logs messages as events appear. If you feel strongly that this is the wrong approach I can close the PR.

@bobbrow
Copy link
Member Author

bobbrow commented Oct 3, 2023

Discussed offline. This will be made better in the C++ part of the code.

@bobbrow bobbrow closed this Oct 3, 2023
@bobbrow bobbrow deleted the bobbrow/fileWatcherExclude branch October 3, 2023 18:42
@github-actions github-actions bot locked and limited conversation to collaborators Nov 18, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants