pyIonControl/IonControl

Measurement log plotting with x-axis other than "started" causes exception

Closed this issue · 1 comments

When attempting to create a plot derived from the measurement log, an exception occurs whenever the x-axis is anything other than "started." The traceback is:

ERROR gui.MeasurementLogUi.MeasurementLogUi(ExceptionLogButton.py:130 myexcepthook) 'NoneType' object is not iterable
Traceback (most recent call last):
File "C:\Users\monroelab\SandiaControlSoftware\IonControl\gui\MeasurementLogUi\MeasurementLogUi.py", line 256, in onCreatePlot
self.doCreatePlot( self.axisDict[self.settings.plotXAxis], self.axisDict[self.settings.plotYAxis], self.settings.plotWindow )
File "C:\Users\monroelab\SandiaControlSoftware\IonControl\gui\MeasurementLogUi\MeasurementLogUi.py", line 304, in doCreatePlot
xData, yData, bottomData, topData = self.getData(xDataDef, yDataDef)
File "C:\Users\monroelab\SandiaControlSoftware\IonControl\gui\MeasurementLogUi\MeasurementLogUi.py", line 287, in getData
xData, _, _ = self.sourceLookup[xsource](measurement, xspace, xname)
TypeError: 'NoneType' object is not iterable

It did work for me for x-axis being different than "started". However, if the parameter is None or inf this expection can be raised. I replaced the return value with (None, None, None). This should fix the exception, but might not plot data either. Should be fixed in develop branch. Please give more details if the problem persists.