diff --git a/src/utility.py b/src/utility.py index 1c2781c..b133583 100644 --- a/src/utility.py +++ b/src/utility.py @@ -34,6 +34,7 @@ def save_dict_list_to_csv(filename, data, query_path=False): print(row) csv_writer.writerow(row) + def save_dict_list_to_csv2(filename, data, query_path=False): """Creates a csv file under the specified path containing one row for each dict in the list 'data'. The file receives a header containing the keys of the first dict entry. @@ -51,6 +52,7 @@ def save_dict_list_to_csv2(filename, data, query_path=False): for row in data: csv_writer.writerow(data[row]) # this line makes issues in original file + def load_dict_list_from_csv(filename, query_path=False): """ Reads a csv file under the specified path containing one row for each dict in the list 'data'. The file header containing the keys of the first dict entry is deleted upon reading.