glTF export: Fix crash when invalid driver
This commit is contained in:
parent
684ef91c1b
commit
cd70923356
|
@ -15,7 +15,7 @@
|
|||
bl_info = {
|
||||
'name': 'glTF 2.0 format',
|
||||
'author': 'Julien Duroure, Scurest, Norbert Nopper, Urs Hanselmann, Moritz Becher, Benjamin Schmithüsen, Jim Eckerlein, and many external contributors',
|
||||
"version": (1, 7, 30),
|
||||
"version": (1, 7, 31),
|
||||
'blender': (2, 91, 0),
|
||||
'location': 'File > Import-Export',
|
||||
'description': 'Import-Export as glTF 2.0',
|
||||
|
|
|
@ -53,6 +53,11 @@ def get_sk_drivers(blender_armature):
|
|||
for sk_c in child.data.shape_keys.animation_data.drivers:
|
||||
# Check if driver is valid. If not, ignore this driver channel
|
||||
try:
|
||||
# Check if driver is valid.
|
||||
# Try/Except is no more a suffisant check, starting with version Blender 3.0,
|
||||
# Blender crashs when trying to resolve path on invalid driver
|
||||
if not sk_c.is_valid:
|
||||
continue
|
||||
sk_name = child.data.shape_keys.path_resolve(get_target_object_path(sk_c.data_path)).name
|
||||
except:
|
||||
continue
|
||||
|
|
Loading…
Reference in New Issue