Unhandeled IndexError
hantangantan opened this issue · 1 comments
hantangantan commented
It is possible to delete the whole parameter table for P/Z and b,a, which results in an IndexError:
Traceback (most recent call last):
File "C:\dev\python\pyfda\pyfda_venv\Lib\site-packages\pyfda\input_widgets\input_coeffs.py", line 940, in _delete_cells
self.refresh_table()
File "C:\dev\python\pyfda\pyfda_venv\Lib\site-packages\pyfda\input_widgets\input_coeffs.py", line 606, in refresh_table
self.ba[1][0] = 1.0 # restore a[0] = 1 of denominator polynome
~~~~~~~~~~^^^
IndexError: index 0 is out of bounds for axis 0 with size 0
Reproduce:
Start pyfda
Select b,a or P/Z tab (leftside)
Select all cells (rows and columns)
Klick on Delete Button (next to clear button)
chipmuenk commented
Confirmed and fixed in develop branch - thanks for reporting!