Mwni / blender-animation-retargeting

Add-on for Blender that allows the transfer of animations and poses from one armature to another
484 stars 48 forks source link

Hard lock during mapping #37

Closed BlackShift closed 2 months ago

BlackShift commented 2 months ago

I can't seem to figure out why, but the add-on hard locks on specific armature with the following error:

Python: Traceback (most recent call last):
  File "C:\Users\Deploy\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\blender-animation-retargeting-stable\main.py", line 39, in draw
    mapping.draw_panel(ctx, layout.box())
  File "C:\Users\Deploy\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\blender-animation-retargeting-stable\mapping.py", line 36, in draw_panel
    bones_n = len(ctx.get_guessing_bones())
  File "C:\Users\Deploy\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\blender-animation-retargeting-stable\context.py", line 132, in get_guessing_bones
    return [bone for bone in bpy.context.selected_pose_bones if bone.name in self.target.pose.bones]
TypeError: 'NoneType' object is not iterable

It seems the addon will get into an invalid state and I can't seem to recover it.

Mwni commented 2 months ago

Neither bpy.context.selected_pose_bones nor self.target.pose.bones should be None. Is source or target hidden or unlinked perhaps?

BlackShift commented 2 months ago

I had some bones hidden, then this came up, I tried un-hiding them, but the issue still persists.

Mwni commented 2 months ago

Without knowing your setup, I cannot help further

BlackShift commented 2 months ago

Is there a way to clear what ever object data or cache that exists? The issue persists across saves. Or is there is no persistent data store?

BlackShift commented 2 months ago

Solved, by going into the context and unchecking ui_guessing_mappings and others image