Skip to content

p.export() with "download_missing" #624

Answered by RhetTbull
moffat asked this question in Q&A
Discussion options

You must be logged in to vote

Yeah, the export() interface exposed by PhotoInfo is pretty limited and meant for quick export but lacks a lot of options like download_missing. You could use "use_photos_export=True" and that will tell export to always use the interface to Photos to export the file (and download it if necessary). Perhaps I should add "download_missing" but there's a more robust PhotoExporter interface that exposes a lot more capability.

try this (I added a few lines so I could actually run the code to test):

import osxphotos
import os 
from osxphotos.photoexporter import ExportOptions, PhotoExporter

photosdb = osxphotos.PhotosDB()
albums = photosdb.albums_shared

basedir = '~/Local/backups/shared_albums'

Replies: 2 comments 12 replies

Comment options

You must be logged in to vote
11 replies
@moffat
Comment options

@RhetTbull
Comment options

@moffat
Comment options

@RhetTbull
Comment options

@moffat
Comment options

Answer selected by moffat
Comment options

You must be logged in to vote
1 reply
@moffat
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants