Win32 File Change Notification does not work on \\Mac UNC "Parallels Shared Folder" shares

Discussion in 'Parallels Desktop for Mac Feature Suggestions' started by DavidH80, Jul 25, 2024.

  1. DavidH80

    DavidH80 Junior Member

    Messages:
    12
    As a sidenote I actually wanted to file a bug report but since you now seem to have made this virtually impossible I'll file it as a feature suggestion instead even though really I believe it is a bug!

    Parallels Desktop 19 for Mac 19.4.1 (54985) with Windows 11 (Arm) VM host machine Apple Silicon although I believe the issue occurs on other architectures as well.
    It appears that if you have a mapped shared drive like this one:
    t: \\Mac\Home\Documents\Projects\Qt
    Parallels Shared Folders
    (net use output)
    That Windows Explorer does not automatically update its view if it's looking at a folder on this mapped drive and a file or directory changes. Now this might seem a little trivial!!? Its not! windows explorer like Manu other applications uses the Win32 file change notification API in order to be able to automatically update the folder view. It uses this API to detect that changes have occurred. It seems that this is not working in the Parallels environment!

    I'm a developer and I use Visual Studio which has GIT integration. I think that VS is using the file change notification API to detect changes to files and automatically update the GIT windows. It sees that because this API does not work on a mapped drive to this sort of location that the GIT windows never update. It means in order to use the GIT integration in VS you have to restart VS. This is most unpleasant and effectively renders the feature useless - probably because of this parallels issue! Its not the only affected program and there are countless others no doubt.
    I recently wrote a program albeit using Qt which used the QT QFileSystemWatcher class. This internally uses the Win32 file change notification API e.g FindFirstChangeNotification etc. It does not detect file or directory changes on my t: drive, works fine on drive c:. I had to wastefully use a timer to periodically check instead! That's just EVIL!

    HOW TO REPLICATE THIS PROBLEM
    This is really simple just use Windows Explorer. Map a drive to a parallels share anywhere in the Mac User Documents area. Use notepad or a command prompt to create a file in a directory currently open (in windows explorer) on the mapped drive. Observe that the folder view does NOT automatically update.

    MORE DETAILED ANALYSIS WOULD LIKELY REQUIRE WRITING A TEST PROGRAM. You can do that yourselves thanks!
     

Share This Page