not_callable_in_transactions(func: Callable[[Node, Any], Any]) Callable[[Node, Any], Any][source]#

Wrapper to prevent certain functions from being used within a transaction.

Certain utils functions which that both get and set values would not work like expected in a transaction. This wrapper prevents misuse by throwing an error in such cases.


func (Callable[[Node, Any], Any]) – function to wrap


Similar function, but not callable from transactions

Return type:

Callable[[Node, Any], Any]