Closed astrofrog closed 7 years ago
A number of bug reports (reported via glue itself) show that under certain circumstances, there can be division by zero here:
Traceback (most recent call last): File "/Users/max/anaconda3/lib/python3.5/site-packages/glue_vispy_viewers/common/viewer_options.py", line 264, in _update_limits self._update_aspect() File "/Users/max/anaconda3/lib/python3.5/site-packages/glue_vispy_viewers/common/viewer_options.py", line 115, in _update_aspect self._vispy_widget._update_limits() File "/Users/max/anaconda3/lib/python3.5/site-packages/glue_vispy_viewers/common/vispy_widget.py", line 122, in _update_limits scale = [2 / (self.options.x_max - self.options.x_min) * self.options.x_stretch * self.options.aspect[0], ZeroDivisionError: float division by zero Traceback (most recent call last):
for instance if the limits are equal. We need to catch and avoid these cases.
A number of bug reports (reported via glue itself) show that under certain circumstances, there can be division by zero here:
for instance if the limits are equal. We need to catch and avoid these cases.