I have reduced the problem down to the Minimal (not ) Working Example. Here I have a cube mesh. I have eight smaller cubes (one at each corner of the larger cube). That’s it.
There are only three steps:
1/ I add Active Rigid Body to each of the small cubes. Collision Shape = ‘Box’. No Collision Margin.
2/ I parent the eight small cubes to the larger cube. The small cubes are the children. The larger cube is the parent. I used Parent (Keep Transform).
I usually do this all in Python but to isolate the problem, I have done steps one and two in the GUI.
3/ With the large cube selected and active, I use the following code to add the Collision Shape = ‘Compound Parent’ to the large cube.
I tried, script1.py
import bpy
bpy.ops.rigidbody.objects_add(type='ACTIVE')
bpy.ops.rigidbody.shape_change(type='COMPOUND')
I also tried, script2.py
import bpy
bpy.ops.rigidbody.objects_add(type='ACTIVE')
bpy.context.object.rigid_body.collision_shape = 'COMPOUND'
There are only two lines! But they throw up nine (not eight) “Dependency cycle detected” reports. Why? What should I change?
Here is the simple Blend file BEFORE I run the Python code. https://pasteall.org/blend/b0b4a0de72ab4a95820a441336d2abfd