Traceback (most recent call last):
File "\Text", line 8, in <module>
File "C:\Program Files\Blender Foundation\Blender 2.90\2.90\scripts\modules\bpy\ops.py", line 201, in __call__
ret = op_call(self.idname_py(), None, kw)
RuntimeError: Operator bpy.ops.view3d.snap_selected_to_cursor.poll() failed, context is incorrect
Error: Python script failed, check the message in the system console
I am typing in this command, because I already got selected object before snapping:
bpy.ops.view3d.snap_selected_to_cursor(use_offset=False)
The question is: why I can not snap selected object to 3d cursor using bpy python while being able to do it by using mouse and keyboard?