diff --git a/frappe/commands/utils.py b/frappe/commands/utils.py index bdddad8cf6..9a0a6113b8 100644 --- a/frappe/commands/utils.py +++ b/frappe/commands/utils.py @@ -254,9 +254,8 @@ def execute(context, method, args=None, kwargs=None, profile=False): try: ret = frappe.get_attr(method)(*args, **kwargs) except Exception: - ret = frappe.safe_eval( - method + "(*args, **kwargs)", eval_globals=globals(), eval_locals=locals() - ) + # eval is safe here because input is from console + ret = eval(method + "(*args, **kwargs)", globals(), locals()) # nosemgrep if profile: import pstats