rotation of active object ?


obj_act = bpy.context.active_object 
 
print ('Active object =',obj_act )
 
obj_sel = bpy.context.selected_objects
 
 
obj_act.rotation_euler = [radians(30.0), 0.0, 0.0]
 

now this rotate the selected object but it also translate it ?

how come there is a translation here ?

i want only a rotation

thanks

solved ?
What is the solution ?

it was my fault

i did not look but in another part later in the script
it was re selecting same object and moving it

i tought i had remove it in txt editor but not in the file
so when i reloaded the file same commands where still there
and did not check that these commands had been remove in the file !

thanks any way