Blender Stack Exchange is a question and answer site for people who use Blender to create 3D graphics, animations, or games. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In my script I tried the following:

import bpy

arm ='SomeName')

and I get the error:

TypeError: bpy_prop_collection[key] = value: invalid, expected a 'Object' type or None, not a 'Armature'

How do I link an armature created with .new() to a scene?

share|improve this question
up vote 6 down vote accepted

Blender has the concept of:

  • Scene: Reference Objects
  • Objects: Reference Object Data (Mesh, Armature, Lamp. etc)

This is needed so you can (for example) have many instances of the same mesh, which saves memory and allows you to edit without having to manually update copies.

Here is the script modified to work as expected.

import bpy

arm ="My Rig")

# create an object
obj ="My Object", arm)
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.