1*4882a593Smuzhiyun{% extends "basebuilddetailpage.html" %} 2*4882a593Smuzhiyun 3*4882a593Smuzhiyun{% load projecttags %} 4*4882a593Smuzhiyun{% load humanize %} 5*4882a593Smuzhiyun 6*4882a593Smuzhiyun{% block title %} {{task.recipe.name}}_{{task.recipe.version}} {{task.task_name}} - {{build.target_set.all|dictsort:"target"|join:", "}} {{build.machine}} - {{build.project.name}} - Toaster {% endblock %} 7*4882a593Smuzhiyun{% block localbreadcrumb %} 8*4882a593Smuzhiyun<li><a href="{% url 'tasks' build.pk %}">Tasks</a></li> 9*4882a593Smuzhiyun<li>{{task.recipe.name}}_{{task.recipe.version}} {{task.task_name}}</li> 10*4882a593Smuzhiyun{% endblock %} 11*4882a593Smuzhiyun 12*4882a593Smuzhiyun{% block pagedetailinfomain %} 13*4882a593Smuzhiyun 14*4882a593Smuzhiyun<div class="row"> 15*4882a593Smuzhiyun <div class="col-md-12"> 16*4882a593Smuzhiyun <div class="page-header build-data"> 17*4882a593Smuzhiyun <h1><a href="{%url 'recipe' build.pk task.recipe.pk %}">{{task.recipe.name}}_{{task.recipe.version}}</a> {{task.task_name}}</h1> 18*4882a593Smuzhiyun </div> 19*4882a593Smuzhiyun 20*4882a593Smuzhiyun{# Outcome section #} 21*4882a593Smuzhiyun<h2 {{ task|task_color:True }}> 22*4882a593Smuzhiyun {{task.get_outcome_display}} 23*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="{{task.get_outcome_help}}"></i> 24*4882a593Smuzhiyun</h2> 25*4882a593Smuzhiyun{%if task.task_executed %} 26*4882a593Smuzhiyun {# executed tasks outcome #} 27*4882a593Smuzhiyun {% if task.logfile %} 28*4882a593Smuzhiyun <a class="btn btn-default btn-lg" 29*4882a593Smuzhiyun href="{% url 'build_artifact' build.id 'tasklogfile' task.pk %}"> 30*4882a593Smuzhiyun Download task log 31*4882a593Smuzhiyun </a> 32*4882a593Smuzhiyun {% endif %} 33*4882a593Smuzhiyun {# show stack trace for failed task #} 34*4882a593Smuzhiyun {% if task.outcome == task.OUTCOME_FAILED and log_head %} 35*4882a593Smuzhiyun <h3>Python stack trace</h3> 36*4882a593Smuzhiyun <div> 37*4882a593Smuzhiyun <pre style="min-height:160px;"> 38*4882a593Smuzhiyun <code>{{log_head}}</code><a id="full-trace-show" data-target="#fulltrace" data-toggle="collapse" class="btn btn-xs">...</a> 39*4882a593Smuzhiyun <div id="fulltrace" class="collapse" style="margin-top: -20px; height: 0px;"> 40*4882a593Smuzhiyun <code>{{log_body}}</code><br><a id="full-trace-hide" class="btn btn-xs collapsed" style="font-family:Helvetica Neue" data-target="#fulltrace" data-toggle="collapse">Collapse stack trace<i class="icon-caret-up"></i></a></div></pre> 41*4882a593Smuzhiyun </div> 42*4882a593Smuzhiyun {% endif %} 43*4882a593Smuzhiyun{% else %} 44*4882a593Smuzhiyun{# not executed tasks outcome #} 45*4882a593Smuzhiyun {% if task.outcome == task.OUTCOME_PREBUILT %} 46*4882a593Smuzhiyun {% if not showing_matches %} 47*4882a593Smuzhiyun <a class="btn btn-default" 48*4882a593Smuzhiyun href="javascript:reload_params({'show_matches' : 'true' 49*4882a593Smuzhiyun })">Match to tasks in previous builds <span class="glyphicon 50*4882a593Smuzhiyunglyphicon-question-sign get-help" title="This shows you a list of tasks from 51*4882a593Smuzhiyunprevious builds with the same signature generated from the same inputs as used 52*4882a593Smuzhiyunin the prebuilt task. Any of them could be the task that generated the output 53*4882a593Smuzhiyunthis prebuilt task is reusing"></span></a> 54*4882a593Smuzhiyun {% elif matching_tasks %} 55*4882a593Smuzhiyun <h3 class="details">Prebuilt task could be based on 56*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="This 57*4882a593Smuzhiyun table shows a list of tasks from previous builds with the 58*4882a593Smuzhiyun same signature generated from the same inputs as used in the 59*4882a593Smuzhiyun prebuilt task. Any of them could be the task that generated the 60*4882a593Smuzhiyun output this prebuilt task is reusing"></span> 61*4882a593Smuzhiyun </h3> 62*4882a593Smuzhiyun <div class="table-responsive"> 63*4882a593Smuzhiyun <table class="table table-bordered table-hover"> 64*4882a593Smuzhiyun <thead> 65*4882a593Smuzhiyun <th> 66*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign 67*4882a593Smuzhiyun get-help" title="The name of the recipe to which 68*4882a593Smuzhiyun each task applies"></span> 69*4882a593Smuzhiyun Recipe 70*4882a593Smuzhiyun </th> 71*4882a593Smuzhiyun <th> 72*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="The name 73*4882a593Smuzhiyun of the task"></span> 74*4882a593Smuzhiyun Task 75*4882a593Smuzhiyun </th> 76*4882a593Smuzhiyun <th> 77*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="This 78*4882a593Smuzhiyun value tells you if a task had to run (executed) in 79*4882a593Smuzhiyun order to generate the task output, or if the output was 80*4882a593Smuzhiyun provided by another task and therefore the task didn't need 81*4882a593Smuzhiyun to run (not executed)"></span> 82*4882a593Smuzhiyun Executed 83*4882a593Smuzhiyun </th> 84*4882a593Smuzhiyun <th> 85*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign 86*4882a593Smuzhiyun get-help" title="This column tells you if 87*4882a593Smuzhiyun 'executed' tasks succeeded or failed. The column also 88*4882a593Smuzhiyun tells you why 'not executed' tasks did not need to 89*4882a593Smuzhiyun run"></span> 90*4882a593Smuzhiyun Outcome 91*4882a593Smuzhiyun </th> 92*4882a593Smuzhiyun <th> 93*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign 94*4882a593Smuzhiyun get-help" title="The date and time the build 95*4882a593Smuzhiyun finished"></span> 96*4882a593Smuzhiyun Build completed on 97*4882a593Smuzhiyun </th> 98*4882a593Smuzhiyun </thead> 99*4882a593Smuzhiyun <tbody> 100*4882a593Smuzhiyun {% for match in matching_tasks %} 101*4882a593Smuzhiyun <tr {{ match|task_color }}> 102*4882a593Smuzhiyun <td> 103*4882a593Smuzhiyun {{match.recipe.name}} 104*4882a593Smuzhiyun </td> 105*4882a593Smuzhiyun <td> 106*4882a593Smuzhiyun <a href="{%url "task" match.build.pk match.pk%}">{{match.task_name}}</a> 107*4882a593Smuzhiyun {% if task.get_description %} 108*4882a593Smuzhiyun <span class="glyphicon 109*4882a593Smuzhiyun glyphicon-question-sign get-help 110*4882a593Smuzhiyun hover-help" 111*4882a593Smuzhiyun title="{{task.get_description}}"></span> 112*4882a593Smuzhiyun {% endif %} 113*4882a593Smuzhiyun </td> 114*4882a593Smuzhiyun <td> 115*4882a593Smuzhiyun {{match.get_executed_display}} 116*4882a593Smuzhiyun </td> 117*4882a593Smuzhiyun <td> 118*4882a593Smuzhiyun {{match.get_outcome_display}} 119*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign 120*4882a593Smuzhiyun get-help hover-help" 121*4882a593Smuzhiyun title="{{match.get_outcome_help}}"></span> 122*4882a593Smuzhiyun </td> 123*4882a593Smuzhiyun <td> 124*4882a593Smuzhiyun {{match.build.completed_on|date:"d/m/y H:i"}} 125*4882a593Smuzhiyun </td> 126*4882a593Smuzhiyun </tr> 127*4882a593Smuzhiyun {% endfor %} 128*4882a593Smuzhiyun </tbody> 129*4882a593Smuzhiyun </table> 130*4882a593Smuzhiyun </div> 131*4882a593Smuzhiyun {% else %} 132*4882a593Smuzhiyun <p class="alert"> 133*4882a593Smuzhiyun <strong> We have found no tasks matching this prebuilt task</strong><br/> 134*4882a593Smuzhiyun The task you are looking for could belong to a build for which Toaster has no data. 135*4882a593Smuzhiyun </p> 136*4882a593Smuzhiyun {% endif %} 137*4882a593Smuzhiyun {% elif task.outcome == task.OUTCOME_COVERED %} 138*4882a593Smuzhiyun <dl class="dl-horizontal"> 139*4882a593Smuzhiyun <dt> 140*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="The task(s) 141*4882a593Smuzhiyun providing the outcome of this task"></span> Task covered by 142*4882a593Smuzhiyun </dt> 143*4882a593Smuzhiyun <dd> 144*4882a593Smuzhiyun <ul class="list-unstyled"> 145*4882a593Smuzhiyun {% for t in covered_by %} 146*4882a593Smuzhiyun <li> 147*4882a593Smuzhiyun <a href="{%url 'task' t.build.pk t.pk%}" 148*4882a593Smuzhiyun class="task-info" 149*4882a593Smuzhiyun title="{{t.get_executed_display}} | {{t.get_outcome_display}}"> 150*4882a593Smuzhiyun {{t.recipe.name}}_{{t.recipe.version}} 151*4882a593Smuzhiyun {{t.task_name}} 152*4882a593Smuzhiyun </a> 153*4882a593Smuzhiyun </li> 154*4882a593Smuzhiyun {% endfor %} 155*4882a593Smuzhiyun </ul> 156*4882a593Smuzhiyun </dd> 157*4882a593Smuzhiyun </dl> 158*4882a593Smuzhiyun {%elif task.outcome == task.OUTCOME_CACHED%} 159*4882a593Smuzhiyun {% for t in task.get_related_setscene %} 160*4882a593Smuzhiyun {% if forloop.last %} 161*4882a593Smuzhiyun <a class="btn btn-default btn-lg" 162*4882a593Smuzhiyun href="{% url 'build_artifact' build.id "tasklogfile" t.pk %}"> 163*4882a593Smuzhiyun Download task log 164*4882a593Smuzhiyun </a> 165*4882a593Smuzhiyun {% endif %} 166*4882a593Smuzhiyun {% endfor %} 167*4882a593Smuzhiyun 168*4882a593Smuzhiyun {%elif task.outcome == task.OUTCOME_EMPTY%} 169*4882a593Smuzhiyun <div class="alert alert-info details"> 170*4882a593Smuzhiyun This task is empty because it has the <code>noexec</code> flag set to <code>1</code>, or the task function is empty 171*4882a593Smuzhiyun </div> 172*4882a593Smuzhiyun {% endif %} 173*4882a593Smuzhiyun{% endif %} 174*4882a593Smuzhiyun 175*4882a593Smuzhiyun{# Execution section #} 176*4882a593Smuzhiyun {% if task.task_executed %} 177*4882a593Smuzhiyun <h2> 178*4882a593Smuzhiyun Executed 179*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" 180*4882a593Smuzhiyun title="'Executed' tasks are those that need to run in order to 181*4882a593Smuzhiyun generate the task output"></span> 182*4882a593Smuzhiyun {% else %} 183*4882a593Smuzhiyun <h2> 184*4882a593Smuzhiyun Not Executed 185*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="'Not 186*4882a593Smuzhiyun executed' tasks don't need to run because their outcome is provided 187*4882a593Smuzhiyun by another task"></span> 188*4882a593Smuzhiyun {% endif %} 189*4882a593Smuzhiyun </h2> 190*4882a593Smuzhiyun 191*4882a593Smuzhiyun<dl class="dl-horizontal"> 192*4882a593Smuzhiyun <dt> 193*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="To make builds more 194*4882a593Smuzhiyun efficient, the build system detects changes in the 'inputs' to a 195*4882a593Smuzhiyun given task by creating a 'task signature'. If the signature changes, 196*4882a593Smuzhiyun the build system assumes the inputs have changed and the task needs to be 197*4882a593Smuzhiyunrerun"></span> 198*4882a593Smuzhiyun Task inputs signature 199*4882a593Smuzhiyun </dt> 200*4882a593Smuzhiyun <dd> 201*4882a593Smuzhiyun {{task.sstate_checksum}} 202*4882a593Smuzhiyun </dd> 203*4882a593Smuzhiyun {% if task.sstate_result != task.SSTATE_NA %} 204*4882a593Smuzhiyun </dl> 205*4882a593Smuzhiyun <div class="alert alert-info">Attempting to restore output from sstate cache 206*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help 207*4882a593Smuzhiyun get-help-blue" title="The build system is searching for the 208*4882a593Smuzhiyun task output in your <code>sstate-cache</code> directory and 209*4882a593Smuzhiyun mirrors. If the build system finds the task output, it will reuse it 210*4882a593Smuzhiyun instead of building it from scratch by running the real task. Reusing the 211*4882a593Smuzhiyun task output makes the build faster"></span> 212*4882a593Smuzhiyun </div> 213*4882a593Smuzhiyun <dl class="dl-horizontal"> 214*4882a593Smuzhiyun <dt> 215*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="The name of the 216*4882a593Smuzhiyun file searched for in your <code>sstate-cache</code> 217*4882a593Smuzhiyun directory and mirrors"></span> 218*4882a593Smuzhiyun File searched for 219*4882a593Smuzhiyun </dt> 220*4882a593Smuzhiyun <dd><code>{{task.path_to_sstate_obj}}</code></dd> 221*4882a593Smuzhiyun <dt> 222*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="The locations 223*4882a593Smuzhiyun searched for the above file (i.e. your 224*4882a593Smuzhiyun <code>sstate-cache</code> directory and any mirrors you have 225*4882a593Smuzhiyun set up)"></span> 226*4882a593Smuzhiyun URI(s) searched 227*4882a593Smuzhiyun </dt> 228*4882a593Smuzhiyun <dd><ul class="list-unstyled">{% for uri in uri_list %}<li><code>{{uri}}</code></li>{% endfor %}</ul></dd> 229*4882a593Smuzhiyun </dl> 230*4882a593Smuzhiyun {% endif %} 231*4882a593Smuzhiyun {% if task.sstate_result == task.SSTATE_MISS %} 232*4882a593Smuzhiyun <div class="alert alert-info"> 233*4882a593Smuzhiyun <strong>File not in sstate cache.</strong> Running the real task instead. 234*4882a593Smuzhiyun </div> 235*4882a593Smuzhiyun {% elif task.sstate_result == task.SSTATE_FAILED%} 236*4882a593Smuzhiyun <div class="alert alert-warning"> 237*4882a593Smuzhiyun <strong>Failed</strong> to restore output from sstate cache. The file was found but could not be unpacked. 238*4882a593Smuzhiyun </div> 239*4882a593Smuzhiyun <dl class="dl-horizontal"> 240*4882a593Smuzhiyun <a href="{% url 'build_artifact' build.id "tasklogfile" task.pk %}" style="margin:15px;">Download log</a> 241*4882a593Smuzhiyun </dl> 242*4882a593Smuzhiyun <div class="alert alert-info"> 243*4882a593Smuzhiyun Running the real task instead. 244*4882a593Smuzhiyun </div> 245*4882a593Smuzhiyun {% elif task.sstate_result == task.SSTATE_RESTORED %} 246*4882a593Smuzhiyun <div class="alert alert-info"> 247*4882a593Smuzhiyun Output <strong>successfully restored</strong> from sstate cache. 248*4882a593Smuzhiyun </div> 249*4882a593Smuzhiyun {% endif %} 250*4882a593Smuzhiyun <dl class="dl-horizontal"> 251*4882a593Smuzhiyun <dt> 252*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="The 253*4882a593Smuzhiyun running sequence of each task in the build"></span> 254*4882a593Smuzhiyun Task order 255*4882a593Smuzhiyun </dt> 256*4882a593Smuzhiyun <dd><a href="{%url "tasks" build.pk %}?page={{task_in_tasks_table_pg}}&limit=25#task-{{task.order}}">{{task.order}}</a></dd> 257*4882a593Smuzhiyun {% if task.task_executed %} 258*4882a593Smuzhiyun <dt> 259*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" 260*4882a593Smuzhiyun title="Indicates if this task executes a Python or Shell 261*4882a593Smuzhiyun function(s)"></span> 262*4882a593Smuzhiyun Task script type 263*4882a593Smuzhiyun </dt> 264*4882a593Smuzhiyun <dd>{{task.get_script_type_display}}</dd> 265*4882a593Smuzhiyun {% endif %} 266*4882a593Smuzhiyun<!-- 267*4882a593Smuzhiyun <dt> 268*4882a593Smuzhiyun <i class="icon-question-sign get-help" title="The code executed by the task"></i> 269*4882a593Smuzhiyun Task executable output 270*4882a593Smuzhiyun </dt> 271*4882a593Smuzhiyun <dd><code>{{task.source_url}}</code></dd> 272*4882a593Smuzhiyun--> 273*4882a593Smuzhiyun <dt> 274*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="Task dependency chain 275*4882a593Smuzhiyun (i.e. other tasks)"></span> 276*4882a593Smuzhiyun Dependencies 277*4882a593Smuzhiyun </dt> 278*4882a593Smuzhiyun <dd> 279*4882a593Smuzhiyun <ul class="list-unstyled"> 280*4882a593Smuzhiyun {% for dep in deps %} 281*4882a593Smuzhiyun <li><a href="{%url 'task' dep.build.pk dep.pk%}" class="task-info" title="{{dep.get_executed_display}} | {{dep.get_outcome_display}}">{{dep.recipe.name}}_{{dep.recipe.version}} <span class="task-name">{{dep.task_name}}</span></a></li> 282*4882a593Smuzhiyun {% empty %} 283*4882a593Smuzhiyun <li class="text-muted" style="margin-bottom: -10px;">This task has no dependencies</li> 284*4882a593Smuzhiyun {% endfor %} 285*4882a593Smuzhiyun </ul> 286*4882a593Smuzhiyun </dd> 287*4882a593Smuzhiyun <dt> 288*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="Tasks that depend on this 289*4882a593Smuzhiyun task"></span> 290*4882a593Smuzhiyun Reverse dependencies 291*4882a593Smuzhiyun </dt> 292*4882a593Smuzhiyun <dd> 293*4882a593Smuzhiyun <ul class="list-unstyled"> 294*4882a593Smuzhiyun {% for dep in rdeps %} 295*4882a593Smuzhiyun <li><a href="{%url 'task' dep.build.pk dep.pk%}" class="task-info" title="{{dep.get_executed_display}} | {{dep.get_outcome_display}}">{{dep.recipe.name}}_{{dep.recipe.version}} <span class="task-name">{{dep.task_name}}</span></a></li> 296*4882a593Smuzhiyun {% empty %} 297*4882a593Smuzhiyun <li class="text-muted">This task has no reverse dependencies</li> 298*4882a593Smuzhiyun {% endfor %} 299*4882a593Smuzhiyun </ul> 300*4882a593Smuzhiyun</dl> 301*4882a593Smuzhiyun 302*4882a593Smuzhiyun{# Performance section - shown only for executed tasks #} 303*4882a593Smuzhiyun{%if task.elapsed_time or task.cpu_time_user or task.cpu_time_system or task.disk_io %} 304*4882a593Smuzhiyun <h2 class="details">Performance</h2> 305*4882a593Smuzhiyun{% endif %} 306*4882a593Smuzhiyun <dl class="dl-horizontal"> 307*4882a593Smuzhiyun {% if task.elapsed_time %} 308*4882a593Smuzhiyun <dt> 309*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="How 310*4882a593Smuzhiyun long it took the task to finish in seconds"></span> 311*4882a593Smuzhiyun Time (secs) 312*4882a593Smuzhiyun </dt> 313*4882a593Smuzhiyun <dd>{{task.elapsed_time|format_none_and_zero|floatformat:2}}</dd> 314*4882a593Smuzhiyun {% endif %} 315*4882a593Smuzhiyun {% if task.cpu_time_user > 0 %} 316*4882a593Smuzhiyun <dt> 317*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="Total amount of time 318*4882a593Smuzhiyun spent executing in user mode, in seconds. Note that this time 319*4882a593Smuzhiyun can be greater than the task time due to parallel 320*4882a593Smuzhiyun execution."></span> 321*4882a593Smuzhiyun User CPU time (secs) 322*4882a593Smuzhiyun </dt> 323*4882a593Smuzhiyun <dd>{{task.cpu_time_user|format_none_and_zero|floatformat:2}}</dd> 324*4882a593Smuzhiyun {% endif %} 325*4882a593Smuzhiyun {% if task.cpu_time_system > 0 %} 326*4882a593Smuzhiyun <dt> 327*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="Total amount of time 328*4882a593Smuzhiyun spent executing in kernel mode, in seconds. Note that this time 329*4882a593Smuzhiyun can be greater than the task time due to parallel 330*4882a593Smuzhiyun execution."></span> 331*4882a593Smuzhiyun System CPU time (secs) 332*4882a593Smuzhiyun </dt> 333*4882a593Smuzhiyun <dd>{{task.cpu_time_system|format_none_and_zero|floatformat:2}}</dd> 334*4882a593Smuzhiyun {% endif %} 335*4882a593Smuzhiyun {% if task.disk_io > 0 %} 336*4882a593Smuzhiyun <dt> 337*4882a593Smuzhiyun <span class="glyphicon glyphicon-question-sign get-help" title="Number of bytes 338*4882a593Smuzhiyun written to and read from the disk during the task"></span> 339*4882a593Smuzhiyun Disk I/O (bytes) 340*4882a593Smuzhiyun </dt> 341*4882a593Smuzhiyun <dd>{{task.disk_io|format_none_and_zero|intcomma}}</dd> 342*4882a593Smuzhiyun {% endif %} 343*4882a593Smuzhiyun </dl> 344*4882a593Smuzhiyun 345*4882a593Smuzhiyun</div> 346*4882a593Smuzhiyun 347*4882a593Smuzhiyun{% endblock %} 348*4882a593Smuzhiyun 349