From 5da5e1201419b9fbce30ea0261137df868f88f95 Mon Sep 17 00:00:00 2001 From: Toke Jepsen Date: Wed, 24 Jul 2019 23:25:14 +0100 Subject: [PATCH 1/2] Start/End frame can be floats. Enforce integer. --- pype/plugins/nuke/load/load_sequence.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pype/plugins/nuke/load/load_sequence.py b/pype/plugins/nuke/load/load_sequence.py index 9dd83de064..c5d8513146 100644 --- a/pype/plugins/nuke/load/load_sequence.py +++ b/pype/plugins/nuke/load/load_sequence.py @@ -130,10 +130,10 @@ class LoadSequence(api.Loader): r["colorspace"].setValue(str(colorspace)) loader_shift(r, first, relative=True) - r["origfirst"].setValue(first) - r["first"].setValue(first) - r["origlast"].setValue(last) - r["last"].setValue(last) + r["origfirst"].setValue(int(first)) + r["first"].setValue(int(first)) + r["origlast"].setValue(int(last)) + r["last"].setValue(int(last)) # add additional metadata from the version to imprint to Avalon knob add_keys = ["startFrame", "endFrame", "handles", From 2a174ef69d8c2d32bb14db12eb27ec1d50e32f2c Mon Sep 17 00:00:00 2001 From: Toke Jepsen Date: Wed, 24 Jul 2019 23:25:52 +0100 Subject: [PATCH 2/2] Handles can be non-existent, in which case they are 0. --- pype/plugins/nuke/load/load_sequence.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pype/plugins/nuke/load/load_sequence.py b/pype/plugins/nuke/load/load_sequence.py index c5d8513146..fd733f7c87 100644 --- a/pype/plugins/nuke/load/load_sequence.py +++ b/pype/plugins/nuke/load/load_sequence.py @@ -94,9 +94,9 @@ class LoadSequence(api.Loader): first = version_data.get("startFrame", None) last = version_data.get("endFrame", None) - handles = version_data.get("handles", None) - handle_start = version_data.get("handleStart", None) - handle_end = version_data.get("handleEnd", None) + handles = version_data.get("handles", 0) + handle_start = version_data.get("handleStart", 0) + handle_end = version_data.get("handleEnd", 0) # fix handle start and end if none are available if not handle_start and not handle_end: