snu-quiqcl / iquip

Ion trap Quantum computing User Interface Project
GNU General Public License v3.0
7 stars 0 forks source link

Dataviewer error when setting threshold #315

Closed kangz12345 closed 1 month ago

kangz12345 commented 1 month ago

Describe the bug

When adjusting the threshold, the terminal shows an error:

Traceback (most recent call last):
  File "C:\Users\QC109_3\iquip\iquip\apps\dataviewer.py", line 1470, in setThreshold
    data = self.dataPoint(self.index)
                          ^^^^^^^^^^
AttributeError: 'DataViewerApp' object has no attribute 'index'

It does not stop the program though.

Expected behavior

The error must not occur.

To Reproduce

Steps to reproduce the behavior:

  1. Open iquip dataviewer
  2. Open a dataset in either realtime or remote mode
  3. Adjust the threshold
  4. See the error in the terminal

Expected causes and correction methods

As the error message indicates, DataViewerApp does not have an attribute index but dataPointIndex. Changing the line to data = self.dataPoint(self.dataPointIndex) would fix the problem.