From 420e9e32a800b45011bc2c3545e02c57c268f619 Mon Sep 17 00:00:00 2001 From: burnettk Date: Tue, 12 Mar 2024 12:11:57 -0400 Subject: [PATCH] let restricted script engine use random --- .../services/process_instance_processor.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_processor.py b/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_processor.py index 3e9da6769..e8d3c376b 100644 --- a/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_processor.py +++ b/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_processor.py @@ -5,6 +5,7 @@ import decimal import json import logging import os +import random import re import time import uuid @@ -319,6 +320,7 @@ class CustomBpmnScriptEngine(PythonScriptEngine): # type: ignore "uuid": uuid, "min": min, "max": max, + "random": random, **JinjaHelpers.get_helper_mapping(), }