I had a small autosmooth script based on this post by user @zeffii
And recently updated to blender 3.4 alpha and somehow the checkbox is not being checked when running the script. Here is the script:
import bpy
import math
selected_objects = bpy.context.selected_objects
for ob in selected_objects:
ob.select_set(True)
ob.data.use_auto_smooth = True
ob.data.use_auto_smooth = 1
ob.data.auto_smooth_angle = math.radians(60) # 40 degrees as radians
bpy.ops.object.shade_smooth()
"use_auto_smooth" part is not working. The checkbox is not being check but the angle is updated. Not sure if its a bug or a mistake in the code?
Also, I used to use 1 but saw that True is now the correct way. Or are both correct to use?

bpy.ops.object.shade_smooth()that unticks the checkbox. Call it before yourforloop. (It was the same in realier versions) – Gorgious Oct 31 '22 at 10:45Trueinstead of1is more semantically correct because the property is representing a boolean value, although I don't think there is any impact code-wise,1is cast to a boolean value automatically. It might have been the only way to set this property in the past. – Gorgious Oct 31 '22 at 10:47