Skip to main content

Run Python File

Executes a Python file with specified arguments and environment variables.

Category: Python Execution · Group: General · Activity name: RunPythonFile

The RunPythonFile activity in the designer

Example

stdout = RunPythonFile("<filePath>", "<interpreterPath>", environment={}, args=[])

Inputs

NameTypeRequiredDefaultDescription
Python File PathstringYesFull path to the Python file to execute.
Python Interpreter PathstringYesPath to the Python interpreter. Use output from SetupPythonEnvironment or specify custom path.
Environment VariablesobjectEnvironment variables to set when running the Python file.
Command Line ArgumentsarrayArguments to pass to the Python script (e.g., ['--input', 'data.csv', '--verbose']).

Outputs

NameTypeDescription
stdoutstringThe standard output from the Python script execution.