diff --git a/openpype/hosts/blender/api/workio.py b/openpype/hosts/blender/api/workio.py index ca15fb3c368..9235d9c2096 100644 --- a/openpype/hosts/blender/api/workio.py +++ b/openpype/hosts/blender/api/workio.py @@ -140,10 +140,10 @@ def check_workfile_up_to_date() -> bool: scene = bpy.context.scene - last_published_time = ( - last_published_version["data"].get("utc_time") - or last_published_version["data"]["time"] + last_published_time = last_published_version["data"].get( + "utc_time", last_published_version["data"]["time"] ) + if scene.get("op_published_time"): return last_published_time <= scene["op_published_time"] else: diff --git a/openpype/hosts/blender/utility_scripts/set_current_time_to_workfile.py b/openpype/hosts/blender/utility_scripts/set_current_time_to_workfile.py index 62161079475..d947d810bfc 100644 --- a/openpype/hosts/blender/utility_scripts/set_current_time_to_workfile.py +++ b/openpype/hosts/blender/utility_scripts/set_current_time_to_workfile.py @@ -5,7 +5,7 @@ from openpype.lib.dateutils import get_timestamp if __name__ == "__main__": - current_time = get_timestamp() + current_time = get_timestamp(datetime_obj=datetime.utcnow()) log = Logger().get_logger() log.debug(f"Setting workfile last publish time to {current_time}")