Commit 3d0b37a8 authored by payno's avatar payno

[orange-add-on][noise reduction] hot fix if user ask for validation and hasn't...

[orange-add-on][noise reduction] hot fix if user ask for validation and hasn't try to update/apply noise reduction first
parent ef5dee31
Pipeline #6696 passed with stage
in 2 minutes and 37 seconds
...@@ -96,7 +96,15 @@ class NoiseReductionOW(OWWidget): ...@@ -96,7 +96,15 @@ class NoiseReductionOW(OWWidget):
def validate(self): def validate(self):
exp = self._widget._experiment exp = self._widget._experiment
if exp is not None: if exp is not None:
self._widget.validate_correction() try:
self._widget.validate_correction()
except ValueError:
# raw fix, in case update has not been activated yet
# TODO: should be managed by buttons availibility or know
# if there is some data in the cache
self._widget._updateCorrection()
self._widget.validate_correction()
assert isinstance(exp, Experiment) assert isinstance(exp, Experiment)
_logger.info('Noise reduction validated') _logger.info('Noise reduction validated')
self.send("data", exp) self.send("data", exp)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment