in mozci/console/commands/batch_execution.py [0:0]
def create_json_file(push, run_id, classification_name, regressions):
to_save = {
"push": {
"id": push.push_uuid,
"classification": classification_name,
},
"failures": {
"real": _serialize_regressions(regressions.real),
"intermittent": _serialize_regressions(regressions.intermittent),
"unknown": _serialize_regressions(regressions.unknown),
},
}
with open(f"{BASE_OUTPUT_DIR}/{push.id}/{run_id}.json", "w") as file:
json.dump(to_save, file, indent=2)