Watcher.subscribe might miss some of many fast subsequent changes
Originally reported as https://github.com/microsoft/vscode/issues/220039
when we do a huge number of file changes then Watcher.subscribe might not always produce all events and thus we miss relevant file changes
a reproducer can be found at https://github.com/cdietrich/parcel-watcher-bug
- on mac air m1 i can see it quite reliably
- on mac m2 pro less
- on linux mint (t480s) rarely but can be seen
This issue is impacting the Test Explorer in the C# Dev Kit Extension. Missing these events causes some tests to be skipped or not recognized properly, leading to a frustrating user experience. We already have a GitHub issue reported here: https://github.com/microsoft/vscode-dotnettools/issues/996
It would be amazing if this could be looked into, as fixing it would really help improve the reliability of the Test Explorer.
@cdietrich I was wondering if there are any updates or plans to address this issue. This bug affects the Test Explorer in C# Dev Kit extension, causing tests to be skipped or not recognized properly. Resolving it would significantly improve reliability for users.
Looking forward to any updates. Thank you.
When running @cdietrich 's demo script, it sometimes (10%?) counts 0 files, and unsubscribe() hangs indefinitely on my Linux machine. I don't know if this is the same problem that was originally reported, but FWIW, upgrading to 2.5.0 fixes this specific issue for me. I believe it may be thanks to this particular fix.
BTW, thanks for the nice demo script Christian, I found it useful to debug on my side.
@ocallesp i just reported the issue as I am affected over a longer dependency chain
Fyi VS Code is trying to update to 2.5.0 for our 1.97.x January release: https://github.com/microsoft/vscode/commit/679a9f1aceeb8b1aa3bcd0542eb5e5aca6046600