ente-io / ente

Fully open source, End to End Encrypted alternative to Google Photos and Apple Photos
https://ente.io
GNU Affero General Public License v3.0
14.73k stars 761 forks source link

adding "Pictures" as a watch folder on macOS does nothing #2495

Open slhale opened 2 months ago

slhale commented 2 months ago

Description

I would like to automatically upload my pictures from my macbook to ente. To do this it seems the way would be to add the "Pictures" folder (~/Pictures) to the "watched folders". Clicking "add folder" and browsing to this folder to select it appears to work in the folder selection, but then nothing happens inside of ente. I also tried dragging the Pictures folder onto ente and that doesn't work either. I made a dummy folder inside of the Pictures folder and tried adding that, which for some reason worked. I don't want to have nested folders in my pictures folder though.

Version

1.7.2

What product are you using?

Ente Photos

What platform are you using?

Desktop - macOS

mnvr commented 2 months ago

There isn't any known issue around this. Can you send your logs to support@ente.io, and also mention in the email how many files (very roughly) are in the top level folder that you're trying to add.

mnvr commented 2 months ago

Ah, wait I think I know what's going on. ~/Pictures is not a normal folder. This is where Apple exports Photos Library.photoslibrary, which is where Apple Photos stores its local library. The information stored here is in Apple's own internal format - watching it will not likely do what you think it will do.

If your intent is to store your photos in both Apple Photos and Ente and have them continually be synced, a better option would be to use the mobile app. If your intent is to store your photos only in Ente, and you just want a one time import, then please use these steps - https://help.ente.io/photos/migration/from-apple-photos/

slhale commented 2 months ago

Hmm, I want to do a secret third option which is to have a folder in my home dir named Pictures in which I store all my pictures, which are then automatically synced to Ente (but not Apple). I suppose your answer means that the closest I will get is using some folder called MyPictures or something instead?

mnvr commented 2 months ago

The problem is not the folder name. The problem is that very likely, your current ~/Pictures only contains one file named Photos Library.photoslibrary. This is not really a file, it is more like a folder itself whose format is Apple's internal thing.

To put it another way, it is not ~/Pictures which is special and causing nothing to be uploaded, it is the fact that (from the Ente app's perspective), there are no photos in ~/Pictures.

If you put normal photos inside ~/Pictures, and then try watching it, it will work (unless I'm missing something and the issue is something else entirely).

slhale commented 2 months ago
Screenshot 2024-07-20 at 11 51 26 AM

I believe that I have regular images in this folder? Some are screenshots and some are downloaded from the internet. I do not have an iPhone or use Apple Photos so I am not sure any other way things would get into the folder.

mnvr commented 2 months ago

It is a permissions issue. macOS doesn't like the app trying to access ~/Pictures/Photos Library.photoslibrary.

remote method 'fsFindFiles': Error: EPERM: operation not permitted, scandir '~/Pictures/Photos Library.photoslibrary'

This error would be present in the logs too, which is why we'd requested for them when you'd emailed support yesterday.

You can either:

Future improvements for the app might be to possibly:

  1. Special case Photos Library.photoslibrary and ignore it.
  2. Try and figure out how to get macOS to show the permissions prompt.

I'm not really sure about doing (2), because with (2) in place people might import ~/Pictures thinking it'll keep their Apple and Ente photos in sync, but it won't do that, it'll just do something that they won't expect. (1) feels like a hack, but is probably the best way to deal with this if multiple folks want to reuse their Pictures folder like this.