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

How to limit virtualenv file watches to prevent large workspace error #19622

Closed
brettcannon opened this issue Aug 3, 2022 Discussed in #19523 · 3 comments
Closed

How to limit virtualenv file watches to prevent large workspace error #19622

brettcannon opened this issue Aug 3, 2022 Discussed in #19523 · 3 comments
Assignees
Labels
area-environments Features relating to handling interpreter environments bug Issue identified by VS Code Team member as probable bug info-needed Issue requires more information from poster triage-needed Needs assignment to the proper sub-team

Comments

@brettcannon
Copy link
Member

Discussed in #19523

Originally posted by ggydush-fn July 21, 2022
I have all of my virtual environments in a single folder (~/.virtualenvs/) and found that this causes the following issue in Vscode (even in an empty project):

Unable to watch for file changes in this large workspace folder. Please follow the instructions link to resolve this issue.

The logs show that the Python extension is watching the ~/.virtualenvs directory, but does it need to watch all files in these directories? When working on multiple projects, this can easily exceed the watcher limit (which I don't have much control over setting, as I'm operating on a remote machine).

Disabling the Python extension resolves, but am wondering if anyone else has come across this and knows a way around it? I've tried modifying Vscode's setting "files.watcherExclude" but that did not seem to have an effect.

@github-actions github-actions bot added the triage-needed Needs assignment to the proper sub-team label Aug 3, 2022
@karthiknadig karthiknadig added bug Issue identified by VS Code Team member as probable bug area-environments Features relating to handling interpreter environments labels Aug 4, 2022
@karrtikr
Copy link

karrtikr commented Aug 4, 2022

Related: microsoft/vscode#151827

@karrtikr
Copy link

@ggydush-fn Ideally the setting should help, I suggest to open a bug in https://github.com/microsoft/vscode/issues, it's possibly the same as microsoft/vscode#151827.

As to what the extension can do, try a couple of things:

  • Do you have poetry environments? I think that's the only global watching extension does is that.
  • Try disabling Pylance extension which also does some watching. Set python.languageServer to Jedi.

Lastly, please provide the logs as mentioned in the issue template. Set python.logging.level to debug in User settings, reload window, then perform the steps to reproduce before providing the logs.

Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

XXX

It contains information as to what and why we watch certain directories.

@karrtikr karrtikr added the info-needed Issue requires more information from poster label Aug 12, 2022
@brettcannon
Copy link
Member Author

Because we have not heard back with the information we requested, we are closing this issue for now. If you are able to provide the info later on then we will be happy to re-open this issue to pick up where we left off.

@brettcannon brettcannon closed this as not planned Won't fix, can't repro, duplicate, stale Sep 29, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-environments Features relating to handling interpreter environments bug Issue identified by VS Code Team member as probable bug info-needed Issue requires more information from poster triage-needed Needs assignment to the proper sub-team
Projects
None yet
Development

No branches or pull requests

3 participants