Skip to content

Commit

Permalink
WIP: get models
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalemario committed Jan 24, 2024
1 parent d48a726 commit ba89e66
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pg_backup_api/pg_backup_api/logic/utility_controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,15 @@ def diagnose() -> 'Response':
else:
server_dict[server] = Server(conf)

available_models = barman.__config__.model_names()
model_dict = {}
for model in available_models: # pyright: ignore
model_dict[model] = barman.__config__.get_model(model)

# errors list with duplicate paths between servers
errors_list = barman.__config__.servers_msg_list

barman_diagnose.exec_diagnose(server_dict, errors_list)
barman_diagnose.exec_diagnose(server_dict, models, errors_list, show_config_source=False)

# new outputs are appended, so grab the last one
stored_output = json.loads(output._writer.json_output["_INFO"][-1])
Expand Down

0 comments on commit ba89e66

Please sign in to comment.