Skip to content

Commit

Permalink
catch error if dataframe does not exist
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonBlanke committed Dec 29, 2023
1 parent cb9dbd2 commit 55ed026
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ def collect_data(self, if_exists="append"):
self.sql_data.save(self.__name__, search_data, if_exists)

def load_search_data(self):
return self.sql_data.load(self.__name__)
try:
dataframe = self.sql_data.load(self.__name__)
except:
print("Path 2 database: ", self.sql_data.path)
return dataframe

def objective_function_dict(self, params):
try:
Expand Down

0 comments on commit 55ed026

Please sign in to comment.