def GET_v1_compile_job_id_hex(job_id):
"""Download a compiled firmware
"""
job = get_job_metadata(job_id)
if not job:
return error("Compile job not found", 404)
if job['result']['firmware']:
return send_file(job['result']['firmware'], mimetype='application/octet-stream', as_attachment=True, attachment_filename=job['result']['firmware_filename'])
return error("Compile job not finished or other error.", 422)
评论列表
文章目录