So after a crazy journey I hope I found the issue.
I will shortly describe my adventure to let readers know how hard sometimes it can be to find some bugs π
I started with the discovery from @Carola. I found an old hard drive and formatted it to exFat
. I won't go into the problem that my Mac didn't recognize it for the longest time π
Finally I made a test and copied a folder with 3 JPG pictures to the newly formatted harddisk. In Watermark I chose this as source folder. As expected, there was the error message reported by Carola. So I assumed that UXP (the technology on which PS plugins are programmed) has problems reading files from exFat
disks. Writing, in fact, went flawlessly.
I searched already submitted Photoshop bugs (I have access to them as a prerelease user) for the keyword exFat
but could not find anything. So once again, I'm going to submit a bug myself. To make it easy for the developers to reproduce the problem I wrote a small plugin that should only read files from an exFat
disk. How could it be otherwise, opening and reading the files in this test plugin worked fine.
So it could not be the file format exFat
. After some trial and error I let the plugin list the filenames it reads from the source folder. Quickly it became clear that this was the problem. There were 6 filenames listed (although I had copied only 3 images). So I looked in the Finder for hidden files that I had overlooked. Even with the hidden files shown, there were only the 3 images.
My script in the plugin listed the following file names:
1.jpg
2.jpg
3.jpg
._1.jpg
._2.jpg
._3.jpg
So there were duplicates with a slightly different file name. Don't ask me why they don't show up in the Finder. They are not really duplicates either. They can't be opened by Photoshop. And of course that was the reason for the error message. I have copied image files over several times. Apparently, no "duplicates" were created when I tried it with my little test plugin.
Here is the reason why these files are created: https://kb.synology.com/en-ro/DSM/tutorial/Why_are_dot_underscore_files_created
Now I have rewritten the plugin to ignore all files where the filename starts with ._
. In the next few days I will submit it to Adobe and hope that this has fixed another problem.