06-10-2024 03:48 PM - edited 06-10-2024 04:15 PM
Is it possible to return a tuple from a python node, e.g.:
def get_tuple():
return (['a', 'b', 'c', ...], [['d', 'e', 'f'], ['g', 'h', 'i'], ...])
I thought you could use a cluster as the return datatype but I have not been having any luck in labview or looking online.
Solved! Go to Solution.
06-10-2024 04:12 PM
What LV/python version? seems to work as expected from LV 2024/python 3.11
The "tuple of lists" also worked when I got rid of the ellipses and passed in arrays with the correct shapes
def get_tuple():
return (['a', 'b', 'c'], [['d', 'e', 'f'], ['g', 'h', 'i']])
06-10-2024 04:22 PM
It is working as expected. Labview had crashed and I didn't realize my input control was empty when I reopened the project, and it was the input that was throwing the error that I mistakenly interpreted as the output tuple throwing the error.