try:
if not str(value) == "":
value = float(re.findall(r"\d{1,2}\.\d{1,2}", str(value))[0])
except:
self.logger.warning("Total pot regex problem: " + str(value))
value = ""
After Change
self.totalPotValue = self.find_value("total_pot_value", screenshot_pilImage, 0.01)
if self.totalPotValue != "":
self.totalPotValue = float(self.totalPotValue)
if self.totalPotValue == "":
self.totalPotValue = 0
self.logger.warning("Total pot regex problem: " + str(value))
self.gui_signals.signal_status.emit("Unable to get pot value")