@login_required
def log_detail_render(request, slug, id):
    # get id params, slug+type
    format = request.GET.get("format", 'raw')
    wf_task_slug = request.GET.get("task")

    orgs = get_my_orgs(request)
    workflow_log = get_object_or_404(WorkflowLog, id=id)
    workflow = get_object_or_404(Workflow, owner__in=orgs, slug=slug)
    lookup_key = unquote_plus(wf_task_slug)
    output_item = workflow_log.outputs[lookup_key]

    try:
        output = output_item['stdout']
    except __HOLE__:
        output = output_item['output']

    if format == 'raw':
        return HttpResponse(output, content_type="text/plain")
    elif format == 'html':
        return HttpResponse(output, content_type="text/html")
dataset/ETHPy150Open 3bot/3bot/threebot/views/workflow.py/log_detail_render