Compile + run the script, returning its top-level ``return`` value.
(source: str, primitives: Mapping[str, Any], args: Any)
| 178 | |
| 179 | |
| 180 | async def execute_workflow(source: str, primitives: Mapping[str, Any], args: Any) -> Any: |
| 181 | """Compile + run the script, returning its top-level ``return`` value.""" |
| 182 | code = compile_workflow(source) |
| 183 | namespace = build_namespace(primitives, args) |
| 184 | exec(code, namespace) # noqa: S102 — curated namespace; see module docstring |
| 185 | return await namespace[_WRAPPER_NAME]() |