Open breun opened 7 hours ago
I've also experienced that after about 2000 pics imported -- not your case! -- the import fails with continuous errors from Photos, so you can use option --stop-on-error 5
for osxphotos to stop running and you can then rerun with --resume
option.
$ osxphotos help import error | cat
Usage: osxphotos import [OPTIONS] [FILES_OR_DIRS]...
Import photos and videos into Photos. Photos will be imported into the most recently opened Photos library.
(...)
Options that match 'error':
-R, --resume Resume previous import, skipping any files which have already been imported. Note: data on each imported file is kept in a database in '/Users/XXX/.local/share/osxphotos/osxphotos_import.db'. This data can be used to resume a previous import if there was an error or the import was cancelled. Any files which were already imported will be skipped. See also --skip-dups. --stop-on-error COUNT Stops importing after COUNT errors. Useful if you experience a large number of errors during import.
### Alternative: use osxphotos sync
* IF you still have access to the source Mac and Photos Library do consider `oxphotos sync`
* Do read the instructions to see if it applies to your case.
```py
Usage: osxphotos sync [OPTIONS]
Sync metadata and albums between Photos libraries.
Use sync to update metadata in a local Photos library to match metadata in
another Photos library. The sync command works by finding identical photos
in the local library and the import source and then updating the metadata in
the local library to match the metadata in the import source. Photos are
considered identical if their original filename and fingerprint match.
The import source can be a Photos library or a metadata export file created
with the --export option.
(...)
osxphotos sync --verbose --timestamp --not-hidden --export MetaData.db --library /path/to/your/PhotosLibrary.photoslibrary/
caffeinate -s osxphotos sync --verbose --timestamp --import MetaData.db --unmatched --merge albums,description,favorite,keywords,location,title --library ~/Pictures/Photos.photoslibrary --report sync.csv
(...)
Importing metadata for DSC01534-a-2.JPG (ABDC3178-96D3-49FF-82A8-DF8B4AE6FF20)
Adding to album ABC
Creating album 'ABC'
Added DSC01534-a-2.JPG (ABDC3178-96D3-49FF-82A8-DF8B4AE6FF20) to album ABC
(...)
Thanks @oPromessa for the detailed reply.
@breun The collection phase is slower than I'd like but shouldn't be this slow. I'll see if I can replicate this to get some additional data.
Describe the bug
I'm trying to import an export created with osxphotos, but after 3.5 hours the step 'Grouping files into import groups' was still at 0%, while the Python process had been running at 100% CPU:
To Reproduce Steps to reproduce the behavior:
There was no error output, but the import process hadn't made any progress in over 3.5 hours.
Expected behavior I expected at least some progress within 3.5 hours.
Desktop (please complete the following information):
osxphotos --version
)osxphotos, version 0.68.6 Python 3.12.7 (main, Oct 5 2024, 01:39:55) [Clang 16.0.0 (clang-1600.0.26.3)] macOS 15.1.0, arm64
Additional context There are 1448 files in
~/Downloads/export
, including AAE files. The export was created on another Mac with this command:osxphotos export --export-aae --exiftool --album "${ALBUM_NAME}" "${DESTINATION}"
.