I suddenly came across this error when I attempted to do
open . to open the current directory in Finder, a command that I use quite frequently:
ysim:~/Downloads$ open . LSOpenURLsWithRole() failed with error -1712 for the file /Users/ysim/Downloads.
It persisted for a few minutes and went away by itself. I tried googling it but the only two hits I saw had to do with ImageMagick and Automator, neither of which I use. Does anyone know why it happens and how to prevent it?