Draft: Resolve "Bug in methods for getting results"
Closes #38
Required snippets
Accessing the last element of a list:
myList = ['aa', 'bb', 'cc']
print(myList[-1])
Regular expression for matching a resultID of the form "3D:RunID:X", where X is an integer with one or more digits:
parseResult = re.search(r"3D:RunID:(\d+)", resultID)
# If a match is found, retrieve the runID
if parseResult:
runID = int(parseResult.group(1))
# Otherwise, raise an exception
else:
raise RuntimeError("resultID did not match the expected pattern.")
To do
-
Correct getSParameters method -
Correct getPower method -
Correct getResultTreeItem method
Edited by Lucas POLO-LOPEZ