This is a question mostly for my curiosity, because I figure there's probably something I'm missing.
When I parent an object (an empty) to a bone in an armature, the object gets placed at the bone tail. (The object has the identity transform.) To the extent that the bone has a location, isn't it the bone head? So why move the child to a location that's a somewhat arbitrary distance from the bone's actual location?
And as long as we're here--what transformation space is the object in once I've done that? If I parent to another object, the child object's transformation space is relative to its parent. If I parent to a bone, is it relative to the bone's world transformation? That would be logical but I'm having trouble with it.
Thanks for any insight.
--
E.g.: I have Suzanne set up with an armature with a single bone and a single unparented Empty hanging out at the origin:
I parent the Empty to the bone with this code:
bpy.data.objects['Empty'].parent = bpy.data.objects['Armature']
bpy.data.objects['Empty'].parent_type = 'BONE'
bpy.data.objects['Empty'].parent_bone = "Bone"
The result is the empty is moved to the bone tail position: