robmcrosby / BlenderUSDZ

Simple USDZ file exporter plugin for Blender3D
GNU General Public License v3.0
474 stars 66 forks source link

deleting objects throws exception #45

Open mildmanjan opened 4 years ago

mildmanjan commented 4 years ago

Hi, this plugin is great, thanks for making it. In Blender 2.82, I make a scene with animations, export to USDZ all works OK. If I go back and delete an object,save, then export it throws an exception:

Traceback (most recent call last): File "/Users/xxx/Library/Application Support/Blender/2.82/scripts/addons/io_scene_usdz/init.py", line 123, in execute return export_usdz.export_usdz(context, **keywords) File "/Users/xxx/Library/Application Support/Blender/2.82/scripts/addons/io_scene_usdz/export_usdz.py", line 40, in export_usdz globalScale = globalScale) File "/Users/xxx/Library/Application Support/Blender/2.82/scripts/addons/io_scene_usdz/export_usdz.py", line 74, in exportUsdData scene.loadContext(context) File "/Users/xxx/Library/Application Support/Blender/2.82/scripts/addons/io_scene_usdz/scene_data.py", line 830, in loadContext bpy.ops.object.mode_set(mode='OBJECT') File "/Applications/Blender.app/Contents/Resources/2.82/scripts/modules/bpy/ops.py", line 201, in call ret = op_call(self.idname_py(), None, kw) RuntimeError: Operator bpy.ops.object.mode_set.poll() failed, context is incorrect

location: :-1

hope thats helpful