Skip to content

Commit

Permalink
catch exception when fold paramters are not able to be updated
Browse files Browse the repository at this point in the history
  • Loading branch information
lachlangrose committed Oct 17, 2024
1 parent 264512c commit 5ee1de5
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,11 @@ def fit(self, params: dict = {}) -> bool:
success = True
except Exception as _e:
logger.error("Could not fit curve to S-Plot, check the wavelength")

self.update_params(guess)
try:
self.update_params(guess)
except Exception as _e:
logger.error("Could not update parameters")
return False
return success
return True

Expand Down

0 comments on commit 5ee1de5

Please sign in to comment.