Advanced Settings Dialog for Python

The Advanced Settings Dialog for Python lets you configure the Python interpreter session settings for the step. The Advanced Settings Dialog for Python contains the following options:

  • Use Adapter Settings for Python Interpreter —Settings configured in Python adapter to determine the Python interpreter session for executing the module.
  • Python Interpreter to use —Interpreter to use for the execution. It has the following options:
    • Object Reference —Use the interpreter session present in interpreter reference.
    • Per Thread —Each thread uses a separate instance of the Python interpreter to execute modules.
    • Per Execution —Each execution uses a separate instance of the Python interpreter to execute modules.
    • Global —All Python modules execute in a single instance of the Python interpreter.
  • Python Version —Python version to use for executing the Python code module.
  • Python Virtual Environment —Path of virtual environment directory to use for executing the Python code module. Leave the field empty to use default environment.
    Note TestStand supports virtual environment created using the virtualenv or venv tool.
  • Interpreter Reference —Location of the object reference variable containing the interpreter session to use for executing the Python code module.
  • Create Interpreter if it does not exist —When enabled, if the variable specified by Interpreter Reference does not contain an interpreter session, executing the step will create an instance of the interpreter session and store in that variable.
  • Pass Array of Numbers as —Sets the default behavior for passing an array of numbers from TestStand to the Python code module. It contains the following options:
    • List —Passes an array of numbers from TestStand to the Python code module as a list of numbers.
    • NumPy Array —Passes an array of numbers from TestStand to the Python code module as a NumPy array of numbers.
    Note You can override the default behavior in the following ways:
    • In the Python Parameter Passing tab of the custom data type properties, configure the Pass Property as setting for subproperties of the named container.
    • In the Python Module tab, configure the Parameter Type to List or NumPy Array.