11-12-2025 03:15 PM - edited 11-12-2025 03:35 PM
Hello,
I created an enum from a Python type in a python module.
Unfortunately, no matter how I delete and recreate this enum, I get this error:
All of the windows that let me select the enum work correctly.
Using TestStand 2025 Q3 64 bit.
11-12-2025 04:16 PM - edited 11-12-2025 04:42 PM
It looks like this is any time that the parameter is configured inside my type palette, whether it be by using a step field, or by typing the full enum value.
Like, if I type Enums.ConnectionMode.FOUR_WIRE in the Step Settings inside the sequence, it works, but if I type the same thing in the Default Module of the custom step, it does not.
11-13-2025 11:30 PM
Based on the behavior, I am guessing that the path to Python module which is configured with the Enum type is relative to sequence file.
To determine what Python path is configured for the TestStand Enum type, do the following: In the types view, for the TestStand Enum type, go to properties (by doing right click on the type) and go to 'Python Parameter Passing' tab in the dialog.
Let me know what path is configured for the Python module in TestSTand type properties and is it a relative path, relative to sequence file.
If it is relative to sequence file, following is the reason you are seeing this behavior:
When TestStand tries to load the Python module to convert TestStand Enum to Python Enum, it uses the Context in which it is used. When using the TestStand Enum in a step present in a sequence file, since the Context knows about sequence file, if using relative path, it searches relative to the sequence file too. In the case of Default Module of custom step type, since it is not attached to any sequence file, the Context does not search relative to any sequence file.
If the configured Python module path for Enum is relative to sequence file, you can do either of the following to ensure TestStand Enum to Python Enum conversion works in all the case:
-Shashidhar