Added version check for M1 macs
This commit is contained in:
@@ -58,8 +58,16 @@ _DB_TABLE_NAMES = {
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
# which major version operating systems have been tested
|
# which version operating systems have been tested
|
||||||
_TESTED_OS_VERSIONS = ["12", "13", "14", "15", "16"]
|
_TESTED_OS_VERSIONS = [
|
||||||
|
("10", "12"),
|
||||||
|
("10", "13"),
|
||||||
|
("10", "14"),
|
||||||
|
("10", "15"),
|
||||||
|
("10", "16"),
|
||||||
|
("11", "0"),
|
||||||
|
("11", "1"),
|
||||||
|
]
|
||||||
|
|
||||||
# Photos 5 has persons who are empty string if unidentified face
|
# Photos 5 has persons who are empty string if unidentified face
|
||||||
_UNKNOWN_PERSON = "_UNKNOWN_"
|
_UNKNOWN_PERSON = "_UNKNOWN_"
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
""" version info """
|
""" version info """
|
||||||
|
|
||||||
__version__ = "0.39.15"
|
__version__ = "0.39.16"
|
||||||
|
|||||||
@@ -85,12 +85,12 @@ class PhotosDB:
|
|||||||
|
|
||||||
# Check OS version
|
# Check OS version
|
||||||
system = platform.system()
|
system = platform.system()
|
||||||
(_, major, _) = _get_os_version()
|
(ver, major, _) = _get_os_version()
|
||||||
if system != "Darwin" or (major not in _TESTED_OS_VERSIONS):
|
if system != "Darwin" or ((ver, major) not in _TESTED_OS_VERSIONS):
|
||||||
logging.warning(
|
logging.warning(
|
||||||
f"WARNING: This module has only been tested with MacOS 10."
|
f"WARNING: This module has only been tested with macOS versions "
|
||||||
f"[{', '.join(_TESTED_OS_VERSIONS)}]: "
|
f"[{', '.join(f'{v}.{m}' for (v, m) in _TESTED_OS_VERSIONS)}]: "
|
||||||
f"you have {system}, OS version: {major}"
|
f"you have {system}, OS version: {ver}.{major}"
|
||||||
)
|
)
|
||||||
|
|
||||||
if verbose is None:
|
if verbose is None:
|
||||||
@@ -1160,9 +1160,9 @@ class PhotosDB:
|
|||||||
self._dbphotos[uuid]["original_orientation"] = row[38]
|
self._dbphotos[uuid]["original_orientation"] = row[38]
|
||||||
self._dbphotos[uuid]["original_filesize"] = row[39]
|
self._dbphotos[uuid]["original_filesize"] = row[39]
|
||||||
|
|
||||||
# visibility state
|
# visibility state
|
||||||
self._dbphotos[uuid]["visibility_state"] = row[42]
|
self._dbphotos[uuid]["visibility_state"] = row[42]
|
||||||
self._dbphotos[uuid]["visible"] = row[42] == 1
|
self._dbphotos[uuid]["visible"] = row[42] == 1
|
||||||
|
|
||||||
# import session not yet handled for Photos 4
|
# import session not yet handled for Photos 4
|
||||||
self._dbphotos[uuid]["import_session"] = None
|
self._dbphotos[uuid]["import_session"] = None
|
||||||
|
|||||||
Reference in New Issue
Block a user