bookmaker_odd_outcome.decimal = float( selection.get('o')) outcomes.append( bookmaker_odd_outcome) odd.title = market.get('n') odd.outcomes = outcomes odds.append(odd) bookmaker_event.odds = odds bookmaker_event.teams = teams bookmaker_event.live = live bookmaker_updater.processEvent(bookmaker_event) except (Exception) as ex: print(bookmaker_title + ' :: Could not process event: ' + str(ex)) bookmaker_updater.finish() # Delete download folder shutil.rmtree(folder_path) # local host IP '127.0.0.1' host = '127.0.0.1' # Define the port on which you want to connect port = 12345
if odd_index == -1: odd = BookmakerOdd.BookmakerOdd() odd.title = event.get('ParentNodeName') odd.outcomes.append(outcome) bookmaker_event.odds.append(odd) else: bookmaker_event.odds[odd_index].outcomes.append(outcome) except (Exception) as ex: pass for key in events_to_process: try: print(bookmaker_title + ' :: Processing API event: ' + events_to_process[key].title) bookmaker_updater.processEvent(events_to_process[key]) except (Exception) as ex: print(bookmaker_title + ' :: Could not process event: ' + str(ex)) bookmaker_updater.finish() # Delete download folder shutil.rmtree(folder_path) # local host IP '127.0.0.1' host = '127.0.0.1' # Define the port on which you want to connect port = 12345 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)