Rigify keeps throwing up Attribute error When I select "Generate rig" #69313

Closed
opened 2019-08-29 21:01:32 +02:00 by Taylor Henson · 10 comments

System Information
Operating system: Windows OS 10
Graphics card: Radeon RX 580 Series

Blender Version
Broken: 2.8
Worked: (optional)

Short description of error
Every time I selected the button Generate rig I keep getting an error message
For the life of me I cannot figure it out.
Doomguy test rig before hitting rigify.blend
Exact steps for others to reproduce the error

  • click Generate Rig
    Based on the default startup or an attached .blend file (as simple as possible).
**System Information** Operating system: Windows OS 10 Graphics card: Radeon RX 580 Series **Blender Version** Broken: 2.8 Worked: (optional) **Short description of error** Every time I selected the button Generate rig I keep getting an error message For the life of me I cannot figure it out. [Doomguy test rig before hitting rigify.blend](https://archive.blender.org/developer/F7709927/Doomguy_test_rig_before_hitting_rigify.blend) **Exact steps for others to reproduce the error** - click Generate Rig Based on the default startup or an attached .blend file (as simple as possible).
Author

Added subscriber: @Taylor-Henson

Added subscriber: @Taylor-Henson

Added subscriber: @AbidMaqbool

Added subscriber: @AbidMaqbool

Thanks for reporting!
Just test it, After pressing Generate Rig, got error:
image.png

Thanks for reporting! Just **test it**, After pressing **Generate Rig**, got **error**: ![image.png](https://archive.blender.org/developer/F7710460/image.png)

Looks like, problemis with user's system (Blender)!
@Taylor-Henson Can you please! Try in same file, by making another rig?
image.png
Then try to Generate Rig Is work for you? (mine is working)
If you got same error, then please!
Try with Load Factory Setting, Enable Rigify...
Let we know!!!

Looks like, **problem**is with **user's system** (Blender)! @Taylor-Henson Can you please! Try in **same file**, by making **another rig**? ![image.png](https://archive.blender.org/developer/F7710488/image.png) Then try to **Generate Rig** Is **work for you**? (mine is **working**) If you **got same error**, then please! Try with **Load Factory Setting**, Enable **Rigify**... Let we know!!!
Member

Added subscriber: @pioverfour

Added subscriber: @pioverfour
Member

This happens when trying to copy bones which have python-created custom properties, but no matching ui_props. In this instance the offending properties most likely come from the blender_mmd_tools add-on.

diff --git a/rigify/utils/bones.py b/rigify/utils/bones.py
index a8e55f9a..f3bb3480 100644
--- a/rigify/utils/bones.py
+++ b/rigify/utils/bones.py
@@ -200,8 +200,10 @@ def copy_bone(obj, bone_name, assign_name=''):
                 prop1 = rna_idprop_ui_prop_get(pose_bone_1, key, create=False)
                 prop2 = rna_idprop_ui_prop_get(pose_bone_2, key, create=True)
                 pose_bone_2[key] = pose_bone_1[key]
-                for key in prop1.keys():
-                    prop2[key] = prop1[key]
+                # if bone only has python-created props but no ui, skip ui props
+                if prop1 is not None:
+                    for key in prop1.keys():
+                        prop2[key] = prop1[key]
 
         bpy.ops.object.mode_set(mode='EDIT')
This happens when trying to copy bones which have python-created custom properties, but no matching ui_props. In this instance the offending properties most likely come from the blender_mmd_tools add-on. ``` diff --git a/rigify/utils/bones.py b/rigify/utils/bones.py index a8e55f9a..f3bb3480 100644 --- a/rigify/utils/bones.py +++ b/rigify/utils/bones.py @@ -200,8 +200,10 @@ def copy_bone(obj, bone_name, assign_name=''): prop1 = rna_idprop_ui_prop_get(pose_bone_1, key, create=False) prop2 = rna_idprop_ui_prop_get(pose_bone_2, key, create=True) pose_bone_2[key] = pose_bone_1[key] - for key in prop1.keys(): - prop2[key] = prop1[key] + # if bone only has python-created props but no ui, skip ui props + if prop1 is not None: + for key in prop1.keys(): + prop2[key] = prop1[key] bpy.ops.object.mode_set(mode='EDIT') ```
Member

Added subscribers: @angavrilov, @lichtwerk

Added subscribers: @angavrilov, @lichtwerk
Member

@angavrilov: can you check on this?

@angavrilov: can you check on this?

This issue was referenced by 6f7d7c35dd

This issue was referenced by 6f7d7c35dda1a0b3b6ec932d2c04ecd7d69bafbd

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Alexander Gavrilov self-assigned this 2019-09-08 21:02:56 +02:00
Sign in to join this conversation.
No Milestone
No project
6 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-addons#69313
No description provided.