summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/toastergui/templates/task.html
diff options
context:
space:
mode:
authorTudor Florea <tudor.florea@enea.com>2014-10-16 03:05:19 +0200
committerTudor Florea <tudor.florea@enea.com>2014-10-16 03:05:19 +0200
commitc527fd1f14c27855a37f2e8ac5346ce8d940ced2 (patch)
treebb002c1fdf011c41dbd2f0927bed23ecb5f83c97 /bitbake/lib/toaster/toastergui/templates/task.html
downloadpoky-daisy-140929.tar.gz
initial commit for Enea Linux 4.0-140929daisy-140929
Migrated from the internal git server on the daisy-enea-point-release branch Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templates/task.html')
-rw-r--r--bitbake/lib/toaster/toastergui/templates/task.html283
1 files changed, 283 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/task.html b/bitbake/lib/toaster/toastergui/templates/task.html
new file mode 100644
index 0000000000..455599932c
--- /dev/null
+++ b/bitbake/lib/toaster/toastergui/templates/task.html
@@ -0,0 +1,283 @@
1{% extends "basebuilddetailpage.html" %}
2
3{% load projecttags %}
4{% load humanize %}
5
6{% block localbreadcrumb %}
7<li><a href="{% url 'tasks' build.pk %}">Tasks</a></li>
8<li>{{task.recipe.name}}_{{task.recipe.version}} {{task.task_name}}</li>
9{% endblock %}
10
11{% block pagedetailinfomain %}
12
13<div class="row span11">
14 <div class="page-header">
15 <h1><a href="{%url 'recipe' build.pk task.recipe.pk %}">{{task.recipe.name}}_{{task.recipe.version}}</a> {{task.task_name}}</h1>
16 </div>
17
18{# Outcome section #}
19<h2 {{ task|task_color:True }}>
20 {{task.get_outcome_display}}
21 <i class="icon-question-sign get-help heading-help" title="{{task.get_outcome_help}}"></i>
22</h2>
23{%if task.task_executed %}
24 {# executed tasks outcome #}
25 <dl class="dl-horizontal">
26 {% if task.logfile %}
27 <dt>
28 <i class="icon-question-sign get-help" title="Path the task log file"></i> Log file
29 </dt>
30 <dd>
31 <code>{{task.logfile}}</code>
32 </dd>
33 {% endif %}
34 {# show stack trace for failed task #}
35 {% if task.outcome == task.OUTCOME_FAILED and log_head %}
36 <h3>Python stack trace</h3>
37 <div>
38 <pre style="min-height:160px;">
39 <code>{{log_head}}</code><a id="full-trace-show" data-target="#fulltrace" data-toggle="collapse" class="btn btn-mini">...</a>
40 <div id="fulltrace" class="collapse" style="margin-top: -20px; height: 0px;">
41 <code>{{log_body}}</code><br><a id="full-trace-hide" class="btn btn-mini collapsed" style="font-family:Helvetica Neue" data-target="#fulltrace" data-toggle="collapse">Collapse stack trace<i class="icon-caret-up"></i></a></div></pre>
42 </div>
43 {% endif %}
44 </dl>
45{% else %}
46{# not executed tasks outcome #}
47 {% if task.outcome == task.OUTCOME_PREBUILT %}
48 {% if not showing_matches %}
49 <a class="btn" href="javascript:reload_params({'show_matches' : 'true' })">Match to tasks in previous builds <i class="icon-question-sign get-help" style="margin-top:20px;" data-toggle="tooltip" title="This shows you a list of tasks from previous builds with the same signature generated from the same inputs as used in the prebuilt task. Any of them could be the task that generated the output this prebuilt task is reusing"></i></a>
50 {% elif matching_tasks %}
51 <h3 class="details">Prebuilt task could be based on
52 <i class="icon-question-sign get-help heading-help" title="This table shows a list of tasks from previous builds with the same signature generated from the same inputs as used in the prebuilt task. Any of them could be the task that generated the output this prebuilt task is reusing"></i>
53 </h3>
54 <table class="table table-bordered table-hover">
55 <thead>
56 <th>
57 <i class="icon-question-sign get-help" title="The name of the recipe to which each task applies"></i>
58 Recipe
59 </th>
60 <th>
61 <i class="icon-question-sign get-help" title="The name of the task"></i>
62 Task
63 </th>
64 <th>
65 <i class="icon-question-sign get-help" title="This value tells you if a task had to run (executed) in order to generate the task output, or if the output was provided by another task and therefore the task didn't need to run (not executed)"></i>
66 Executed
67 </th>
68 <th>
69 <i class="icon-question-sign get-help" title="This column tells you if 'executed' tasks succeeded or failed. The column also tells you why 'not executed' tasks did not need to run"></i>
70 Outcome
71 </th>
72 <th>
73 <i class="icon-question-sign get-help" title="The date and time the build finished"></i>
74 Build completed on
75 </th>
76 </thead>
77 <tbody>
78 {% for match in matching_tasks %}
79 <tr {{ match|task_color }}>
80 <td>
81 <a href="{%url "task" match.build.pk match.pk%}">{{match.recipe.name}}</a>
82 </td>
83 <td>
84 <a href="{%url "task" match.build.pk match.pk%}">{{match.task_name}}</a>
85 </td>
86 <td>
87 <a href="{%url "task" match.build.pk match.pk%}">{{match.get_executed_display}}</a>
88 </td>
89 <td>
90 <a href="{%url "task" match.build.pk match.pk%}">{{match.get_outcome_display}} </a><i class="icon-question-sign get-help hover-help" title="{{match.get_outcome_help}}"></i>
91 </td>
92 <td>
93 <a href="{%url "task" match.build.pk match.pk%}">{{match.build.completed_on|date:"d/m/y H:i"}}</a>
94 </td>
95 </tr>
96 {% endfor %}
97 </tbody>
98 </table>
99 {% else %}
100 <p class="alert">
101 <strong> We have found no tasks matching this prebuilt task</strong><br/>
102 The task you are looking for could belong to a build for which Toaster has no data.
103 </p>
104 {% endif %}
105 {% elif task.outcome == task.OUTCOME_COVERED %}
106 <dl class="dl-horizontal">
107 <dt>
108 <i class="icon-question-sign get-help" title="The task providing the outcome of this task"></i> Task covered by
109 </dt>
110 <dd>
111 <ul>
112 {% for t in covered_by %}
113 <li>
114 <a href="{%url 'task' t.build.pk t.pk%}"
115 class="task-info"
116 title="{{t.get_executed_display}} | {{t.get_outcome_display}}">
117 {{t.recipe.name}}_{{t.recipe.version}}
118 {{t.task_name}}
119 </a>
120 </li>
121 {% endfor %}
122 </ul>
123 </dd>
124 </dl>
125 {%elif task.outcome == task.OUTCOME_CACHED%}
126 <dl class="dl-horizontal">
127 <dt>
128 <i class="icon-question-sign get-help" title="Path the task log file"></i> Log file
129 </dt>
130 <dd>
131 <code>{% for t in task.get_related_setscene %} {{t.logfile}} {% endfor %}</code>
132 </dd>
133 </dl>
134 {%elif task.outcome == task.OUTCOME_EMPTY%}
135 <div class="alert alert-info details">
136 This task is empty because it has the <code>noexec</code> flag set to <code>1</code>, or the task function is empty
137 </div>
138 {% endif %}
139{% endif %}
140
141{# Execution section #}
142 {% if task.task_executed %}
143 <h2>
144 Executed
145 <i class="icon-question-sign get-help heading-help" title="'Executed' tasks are those that need to run in order to generate the task output"></i>
146 {% else %}
147 <h2 class="muted">
148 Not Executed
149 <i class="icon-question-sign get-help heading-help" title="'Not executed' tasks don't need to run because their outcome is provided by another task"></i>
150 {% endif %}
151 </h2>
152<dl class="dl-horizontal">
153 <dt>
154 <i class="icon-question-sign get-help" title="To make builds more efficient, the build system detects changes in the 'inputs' to a given task by creating a 'task signature'. If the signature changes, the build system assumes the inputs have changed and the task needs to be rerun"></i>
155 Task inputs signature
156 </dt>
157 <dd>
158 {{task.sstate_checksum}}
159 </dd>
160 {% if task.sstate_result != task.SSTATE_NA %}
161 </dl>
162 <div class="alert alert-info">Attempting to restore output from sstate cache
163 <i class="icon-question-sign get-help get-help-blue" title="The build system is searching for the task output in your <code>sstate-cache</code> directory and mirrors. If the build system finds the task output, it will reuse it instead of building it from scratch by running the real task. Reusing the task output makes the build faster"></i>
164 </div>
165 <dl class="dl-horizontal">
166 <dt>
167 <i class="icon-question-sign get-help" title="The name of the file searched for in your <code>sstate-cache</code> directory and mirrors"></i>
168 File searched for
169 </dt>
170 <dd><code>{{task.path_to_sstate_obj}}</code></dd>
171 <dt>
172 <i class="icon-question-sign get-help" title="The locations searched for the above file (i.e. your <code>sstate-cache</code> directory and any mirrors you have set up)"></i>
173 URI(s) searched
174 </dt>
175 <dd><ul>{% for uri in uri_list %}<li><code>{{uri}}</code></li>{% endfor %}</ul></dd>
176 </dl>
177 {% endif %}
178 {% if task.sstate_result == task.SSTATE_MISS %}
179 <div class="alert alert-info">
180 <strong>File not in sstate cache.</strong> Running the real task instead.
181 </div>
182 {% elif task.sstate_result == task.SSTATE_FAILED%}
183 <div class="alert">
184 <strong>Failed</strong> to restore output from sstate cache. The file was found but could not be unpacked.
185 </div>
186 <dl class="dl-horizontal">
187 <dt>
188 <i class="icon-question-sign get-help" title="Path to the cache attempt log file"></i>
189 Log file
190 </dt>
191 <dd><code>{{task.logfile}}</code></dd>
192 <dt>
193 <i class="icon-question-sign get-help" title="How long it took the cache attempt to finish in seconds"></i>
194 Time (secs)
195 </dt>
196 <dd>{{task.elapsed_time|format_none_and_zero}}</dd>
197 </dl>
198 <div class="alert alert-info">
199 Running the real task instead.
200 </div>
201 {% elif task.sstate_result == task.SSTATE_RESTORED %}
202 <div class="alert alert-info">
203 Output <strong>successfully restored</strong> from sstate cache.
204 </div>
205 {% endif %}
206 <dl class="dl-horizontal">
207 <dt>
208 <i class="icon-question-sign get-help" title="The running sequence of each task in the build"></i>
209 Task order
210 </dt>
211 <dd><a href="{%url "tasks_task" build.pk task.order %}#{{task.order}}">{{task.order}}</a></dd>
212 {% if task.task_executed %}
213 <dt>
214 <i class="icon-question-sign get-help" title="Indicates if this task executes a Python or Shell function(s)"></i>
215 Task script type
216 </dt>
217 <dd>{{task.get_script_type_display}}</dd>
218 {% endif %}
219<!--
220 <dt>
221 <i class="icon-question-sign get-help" title="The code executed by the task"></i>
222 Task executable output
223 </dt>
224 <dd><code>{{task.source_url}}</code></dd>
225-->
226 <dt>
227 <i class="icon-question-sign get-help" title="Task dependency chain (i.e. other tasks)"></i>
228 Dependencies
229 </dt>
230 <dd>
231 <ul>
232 {% for dep in deps %}
233 <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>
234 {% empty %}
235 <li class="muted">This task has no dependencies</li>
236 {% endfor %}
237 </ul>
238 </dd>
239 <dt>
240 <i class="icon-question-sign get-help" title="Tasks that depend on this task"></i>
241 Reverse dependencies
242 </dt>
243 <dd>
244 <ul>
245 {% for dep in rdeps %}
246 <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>
247 {% empty %}
248 <li class="muted">This task has no reverse dependencies</li>
249 {% endfor %}
250 </ul>
251</dl>
252
253{# Performance section - shown only for executed tasks #}
254{%if task.elapsed_time or task.cpu_usage or task.disk_io %}
255 <h2 class="details">Performance</h2>
256{% endif %}
257 <dl class="dl-horizontal">
258 {% if task.elapsed_time %}
259 <dt>
260 <i class="icon-question-sign get-help" title="How long it took the task to finish in seconds"></i>
261 Time (secs)
262 </dt>
263 <dd>{{task.elapsed_time|format_none_and_zero|floatformat:2}}</dd>
264 {% endif %}
265 {% if task.cpu_usage > 0 %}
266 <dt>
267 <i class="icon-question-sign get-help" title="The percentage of task CPU utilization"></i>
268 CPU usage
269 </dt>
270 <dd>{{task.cpu_usage|format_none_and_zero|floatformat:2}}%</dd>
271 {% endif %}
272 {% if task.disk_io > 0 %}
273 <dt>
274 <i class="icon-question-sign get-help" title="Number of miliseconds the task spent doing disk input and output"></i>
275 Disk I/O (ms)
276 </dt>
277 <dd>{{task.disk_io|format_none_and_zero}}</dd>
278 {% endif %}
279 </dl>
280
281</div>
282{% endblock %}
283