Description
Issue Type: Bug
When opening a typescript a(n empty) folder I get the error message:
Unable to watch for file changes in this large workspace folder. Please follow the instructions link to resolve this issue.
But it is not large at all. In fact it is enough to have only one not a single file in the "project" folder!
mkdir empty
Now opening this empty
folder in VSCode leeds to the mentioned error message.
Before you ask:
$ cat /proc/sys/fs/inotify/max_user_watches
65536
and it does not help if set to the 512K maximum.
Findings:
- The FS watcher seems to look for a
.git
folder - that does not exist in theempty
"project". - The watcher obviously climbs up the FS hierarchy towards the root folder until it finds a
.git
folder. - My
$HOME
is managed by git (for dotfiles mainly), so I have a.git
directory in it. - Workaround 1: When I temporarily remove
~/.git
the error does not appear when opening theempty
folder w/ VSCode. - Workaround 2:
git init
in theempty
folder.
Looks like the watcher is climbing up the folder structure until it finds a .git
folder - in my case up to the $HOME
directory that naturally contains a lot of files. This does not seem to make much sense as the .git
folder does not necessarily belongs to the actual project.
I did not have the issue when I installed typescript (4.7.3) in the empty
folder, created a proper tsconfig.json
and ran npx tsc -w
, so the error does not seem to come from the original ts watcher.
I am not sure if this is really a VSCode issue or comes from some component used by VSC.
VS Code version: Code 1.68.0 (4af164e, 2022-06-08T11:49:57.055Z)
OS version: Linux x64 5.3.18-150300.59.68-default
Restricted Mode: No
System Info
Item | Value |
---|---|
CPUs | Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz (8 x 4087) |
GPU Status | 2d_canvas: enabled canvas_oop_rasterization: disabled_off direct_rendering_display_compositor: disabled_off_ok gpu_compositing: enabled multiple_raster_threads: enabled_on oop_rasterization: disabled_off opengl: enabled_on rasterization: disabled_software raw_draw: disabled_off_ok skia_renderer: enabled_on video_decode: disabled_software video_encode: disabled_software vulkan: disabled_off webgl: enabled webgl2: enabled |
Load (avg) | 1, 1, 1 |
Memory (System) | 31.24GB (15.82GB free) |
Process Argv | --unity-launch --crash-reporter-id b4d4e202-8269-4b94-ad97-a926191ab2fe |
Screen Reader | no |
VM | 0% |
DESKTOP_SESSION | /usr/share/xsessions/plasma5 |
XDG_CURRENT_DESKTOP | KDE |
XDG_SESSION_DESKTOP | KDE |
XDG_SESSION_TYPE | x11 |
Extensions (23)
Extension | Author (truncated) | Version |
---|---|---|
pug | ama | 1.0.1 |
vscode-django | bat | 1.10.0 |
path-intellisense | chr | 2.8.1 |
vscode-eslint | dba | 2.2.2 |
vscode-babel-coloring | dza | 0.0.4 |
EditorConfig | Edi | 0.16.4 |
prettier-vscode | esb | 9.5.0 |
VS-code-vagrantfile | mar | 0.0.7 |
vscode-docker | ms- | 1.22.0 |
python | ms- | 2022.8.0 |
vscode-pylance | ms- | 2022.6.10 |
jupyter | ms- | 2022.5.1001601848 |
jupyter-keymap | ms- | 1.0.0 |
jupyter-renderers | ms- | 1.0.8 |
remote-containers | ms- | 0.238.2 |
angular2-inline | nat | 0.0.17 |
color-highlight | nau | 2.5.0 |
vetur | oct | 0.35.0 |
material-icon-theme | PKi | 4.18.1 |
LiveServer | rit | 5.7.5 |
jinjahtml | sam | 0.17.0 |
autoimport | ste | 1.5.4 |
vscode-icons | vsc | 11.12.0 |
(2 theme extensions excluded)