mono / monodevelop

MonoDevelop is a cross platform .NET IDE
http://www.monodevelop.com
2.84k stars 1.02k forks source link

[Core] Handle odd file watcher events causing solution to be closed #9467

Closed mrward closed 4 years ago

mrward commented 4 years ago

The file watcher seems to sometimes produce strange events which look like a directory being renamed to a file. This can cause the IDE to believe the solution file has been deleted since the file service will raise a FileRemoved event for a rename. To avoid this check that the directory does not exist and if it does the FileRemoved event is not fired with this type of rename.

Fixes VSTS #1027550 - VSMac keeps closing my solution

migueldeicaza commented 4 years ago

So far this looks fine - have not tested as much as I would like to, but I have not triggered this problem yet.