PyDoc: bpy.types.Operator docs - add note on execution context
Clarify the default behavior when invoke and execute is called. Ref: !135854
This commit is contained in:
committed by
Campbell Barton
parent
224b8bb116
commit
ad5494d7ac
@@ -14,6 +14,10 @@ Common return values are ``{'FINISHED'}`` and ``{'CANCELLED'}``, the latter
|
||||
meaning that the operator execution was aborted without making any changes or
|
||||
saving an undo history entry.
|
||||
|
||||
If operator was cancelled but there wasn't any reports from it with ``{'ERROR'}`` type,
|
||||
it will just return ``{'CANCELLED'}`` without raising any exceptions.
|
||||
If it had error reports, then it will raise a ``RuntimeError`` including all report messages.
|
||||
|
||||
Calling an operator in the wrong context will raise a ``RuntimeError``,
|
||||
there is a poll() method to avoid this problem.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user