Sierra & SMB & Synology NAS & Applescript crashes Finder
I've discovered a bug that I don't know how to fix. I'm able to repeat the problem. So I have an Applescript (fired via FileMaker) that tells the mac to highlight a certain file in an already opened Finder window connected to a shared folder on a Synology NAS server. This problem even happens if I run the script within the Script Editor app. Here's the Applescript:
set theFile to "West Office Files:_Scan Inbox:LAR:1002.pdf"
tell application "Finder"
reveal document file theFile
end tell
An error pops up saying the apple event doesn't understand the "reveal" message with an error code of -1708. I have also tried using "select" instead of "reveal" and the problem persists.
Then strange things begin to happen in Finder. Can't click on a finder window showing files, can't close any windows. Sometimes Finder will start popping up what I call "shadow boxes" which is the drop shadow of a window, but the window is invisible. Finder won't correct itself and the only fix I've found is to quickly log out the user to the Mac login screen and log back in. If I don't Finder will get worse and ultimately require a force restart.
This is ONLY happening with MacOS Sierra (any sub version) and when connected to a Synology NAS server (using DSM 6+) via SMB. AFP works fine, pre-Sierra Mac OSes work fine, and even when connected to an old Mac OS (Lion) Server via SMB or AFP there is no problem.
Anyone experiencing this?
iMac with Retina 5K display, macOS Sierra (10.12.5)