Trying this very basic simple straight forward script, invoked by console command
$ blender --python basic_script.py
#! basic_script.py
# add a primitive cylinder
bpy.ops.mesh.primitive_cylinder_add()
# toggle into edit
bpy.ops.object.editmode_toggle()
# resize, works perfect
bpy.ops.transform.resize(value=(0.01, 0.01, 5))
# move, works perfect
bpy.ops.transform.translate(value=(0, 0, 5))
# rotate, poll()wrong context, What!??
bpy.ops.transform.rotate(value=1.5708, orient_axis='X', orient_type='GLOBAL')
100 possible answers, none of em worked
bpy.ops.transform.rotate(value=1.5708, orient_axis='X', orient_type='GLOBAL', orient_matrix=((1, 0, 0), (0, 1, 0), (0, 0, 1)), orient_matrix_type='GLOBAL', constraint_axis=(True, False, False), mirror=True, use_proportional_edit=False, proportional_edit_falloff='SMOOTH', proportional_size=1, use_proportional_connected=False, use_proportional_projected=False)
- not sure how much of that you truly need - perhaps just the matrix transform. I think if you leave it out, you need to set the rotation in radians which requires you toimport math
.. $\endgroup$