docs: def analysis(analysis_id):
      """Display a single analysis."""
      analysis_obj = store.analysis(analysis_id)
      if analysis_obj is None:
          return abort(404)
  
      if request.method == 'PUT':
          analysis_obj.update(request.json)
          store.commit()
  
      data = analysis_obj.to_dict()
      data['failed_jobs'] = [job_obj.to_dict() for job_obj in analysis_obj.failed_jobs]
      data['user'] = analysis_obj.user.to_dict() if analysis_obj.user else None
      return jsonify(**data)