temporary fix for missing path on shared photos
This commit is contained in:
@@ -830,7 +830,8 @@ class PhotosDB:
|
|||||||
"ZGENERICASSET.ZFILENAME, "
|
"ZGENERICASSET.ZFILENAME, "
|
||||||
"ZGENERICASSET.ZLATITUDE, "
|
"ZGENERICASSET.ZLATITUDE, "
|
||||||
"ZGENERICASSET.ZLONGITUDE, "
|
"ZGENERICASSET.ZLONGITUDE, "
|
||||||
"ZGENERICASSET.ZHASADJUSTMENTS "
|
"ZGENERICASSET.ZHASADJUSTMENTS, "
|
||||||
|
"ZGENERICASSET.ZCLOUDOWNERHASHEDPERSONID "
|
||||||
"FROM ZGENERICASSET "
|
"FROM ZGENERICASSET "
|
||||||
"JOIN ZADDITIONALASSETATTRIBUTES ON ZADDITIONALASSETATTRIBUTES.ZASSET = ZGENERICASSET.Z_PK "
|
"JOIN ZADDITIONALASSETATTRIBUTES ON ZADDITIONALASSETATTRIBUTES.ZASSET = ZGENERICASSET.Z_PK "
|
||||||
"WHERE ZGENERICASSET.ZTRASHEDSTATE = 0 AND ZGENERICASSET.ZKIND = 0 "
|
"WHERE ZGENERICASSET.ZTRASHEDSTATE = 0 AND ZGENERICASSET.ZKIND = 0 "
|
||||||
@@ -853,6 +854,7 @@ class PhotosDB:
|
|||||||
# 13 "ZGENERICASSET.ZLATITUDE, "
|
# 13 "ZGENERICASSET.ZLATITUDE, "
|
||||||
# 14 "ZGENERICASSET.ZLONGITUDE, "
|
# 14 "ZGENERICASSET.ZLONGITUDE, "
|
||||||
# 15 "ZGENERICASSET.ZHASADJUSTMENTS "
|
# 15 "ZGENERICASSET.ZHASADJUSTMENTS "
|
||||||
|
# 16 "ZCLOUDOWNERHASHEDPERSONID "
|
||||||
|
|
||||||
i = 0
|
i = 0
|
||||||
for row in c:
|
for row in c:
|
||||||
@@ -860,6 +862,11 @@ class PhotosDB:
|
|||||||
uuid = row[0]
|
uuid = row[0]
|
||||||
logging.debug(f"i = {i:d}, uuid = '{uuid}")
|
logging.debug(f"i = {i:d}, uuid = '{uuid}")
|
||||||
|
|
||||||
|
# TODO: temporary fix for shared cloud photos
|
||||||
|
if row[16] is not None:
|
||||||
|
logging.debug(f"skipping shared cloud photo {uuid}, ZCLOUDOWNERHASHEDPERSONID: {row[16]}")
|
||||||
|
continue
|
||||||
|
|
||||||
self._dbphotos[uuid] = {}
|
self._dbphotos[uuid] = {}
|
||||||
self._dbphotos[uuid]["_uuid"] = uuid # stored here for easier debugging
|
self._dbphotos[uuid]["_uuid"] = uuid # stored here for easier debugging
|
||||||
self._dbphotos[uuid]["modelID"] = None
|
self._dbphotos[uuid]["modelID"] = None
|
||||||
@@ -893,6 +900,7 @@ class PhotosDB:
|
|||||||
self._dbphotos[uuid]["longitude"] = row[14]
|
self._dbphotos[uuid]["longitude"] = row[14]
|
||||||
|
|
||||||
self._dbphotos[uuid]["hasAdjustments"] = row[15]
|
self._dbphotos[uuid]["hasAdjustments"] = row[15]
|
||||||
|
self._dbphotos[uuid]["cloudOwnerHashedPersonID"] = row[16]
|
||||||
|
|
||||||
# these will get filled in later
|
# these will get filled in later
|
||||||
# init to avoid key errors
|
# init to avoid key errors
|
||||||
|
|||||||
Reference in New Issue
Block a user