bitbake: toaster: adjust build dashboard for failed builds
Remove the side bar and build details modules for failed builds. [YOCTO #8443] (Bitbake rev: 9d68a5bfdccd399791e1af048fefa73b5df90bcb) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
e387a7ab9d
commit
2d80b902b8
|
@ -52,104 +52,106 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<!-- begin left sidebar container for builds which started properly -->
|
||||||
<!-- begin left sidebar container -->
|
{% if build.started %}
|
||||||
<div id="nav" class="col-md-2">
|
<div class="row">
|
||||||
<ul class="nav nav-pills nav-stacked" id="build-menu">
|
<div id="nav" class="col-md-2">
|
||||||
<li
|
<ul class="nav nav-pills nav-stacked" id="build-menu">
|
||||||
{% if request.resolver_match.url_name == 'builddashboard' %}
|
<li
|
||||||
class="active"
|
{% if request.resolver_match.url_name == 'builddashboard' %}
|
||||||
{% endif %} >
|
class="active"
|
||||||
<a href="{% url 'builddashboard' build.pk %}">Build summary</a>
|
{% endif %} >
|
||||||
</li>
|
<a href="{% url 'builddashboard' build.pk %}">Build summary</a>
|
||||||
{% if build.has_images and build.outcome == build.SUCCEEDED %}
|
</li>
|
||||||
<li class="nav-header" data-menu-heading="images">Images</li>
|
{% if build.has_images and build.outcome == build.SUCCEEDED %}
|
||||||
{% block nav-target %}
|
<li class="nav-header" data-menu-heading="images">Images</li>
|
||||||
{% for t in build.get_sorted_target_list %}
|
{% block nav-target %}
|
||||||
{% if t.has_images %}
|
{% for t in build.get_sorted_target_list %}
|
||||||
<li id="menu-{{t.target}}"><a href="{% url 'target' build.pk t.pk %}">{{t.target}}</a><li>
|
{% if t.has_images %}
|
||||||
{% endif %}
|
<li id="menu-{{t.target}}"><a href="{% url 'target' build.pk t.pk %}">{{t.target}}</a><li>
|
||||||
{% endfor %}
|
{% endif %}
|
||||||
{% endblock %}
|
{% endfor %}
|
||||||
{% endif %}
|
{% endblock %}
|
||||||
<li class="nav-header">Build</li>
|
{% endif %}
|
||||||
<li id="menu-configuration"><a href="{% url 'configuration' build.pk %}">Configuration</a></li>
|
<li class="nav-header">Build</li>
|
||||||
<li><a href="{% url 'tasks' build.pk %}">Tasks</a></li>
|
<li id="menu-configuration"><a href="{% url 'configuration' build.pk %}">Configuration</a></li>
|
||||||
<li><a href="{% url 'recipes' build.pk %}">Recipes</a></li>
|
<li><a href="{% url 'tasks' build.pk %}">Tasks</a></li>
|
||||||
<li><a href="{% url 'packages' build.pk %}">Packages</a></li>
|
<li><a href="{% url 'recipes' build.pk %}">Recipes</a></li>
|
||||||
<li class="nav-header">Performance</li>
|
<li><a href="{% url 'packages' build.pk %}">Packages</a></li>
|
||||||
<li><a href="{% url 'buildtime' build.pk %}">Time</a></li>
|
<li class="nav-header">Performance</li>
|
||||||
<li><a href="{% url 'cputime' build.pk %}">CPU usage</a></li>
|
<li><a href="{% url 'buildtime' build.pk %}">Time</a></li>
|
||||||
<li><a href="{% url 'diskio' build.pk %}">Disk I/O</a></li>
|
<li><a href="{% url 'cputime' build.pk %}">CPU usage</a></li>
|
||||||
|
<li><a href="{% url 'diskio' build.pk %}">Disk I/O</a></li>
|
||||||
|
|
||||||
<li class="nav-header">Actions</li>
|
<li class="nav-header">Actions</li>
|
||||||
<a class="btn btn-default btn-block navbar-btn" href="{% url 'build_artifact' build.id 'cookerlog' build.id %}">Download build log</a>
|
<a class="btn btn-default btn-block navbar-btn" href="{% url 'build_artifact' build.id 'cookerlog' build.id %}">Download build log</a>
|
||||||
|
|
||||||
{% with build.get_custom_image_recipes as custom_image_recipes %}
|
{% with build.get_custom_image_recipes as custom_image_recipes %}
|
||||||
{% if custom_image_recipes.count > 0 %}
|
{% if custom_image_recipes.count > 0 %}
|
||||||
<!-- edit custom image built during this build -->
|
<!-- edit custom image built during this build -->
|
||||||
<button class="btn btn-default btn-block navbar-btn" data-role="edit-custom-image-trigger">Edit custom image</button>
|
<button class="btn btn-default btn-block navbar-btn" data-role="edit-custom-image-trigger">Edit custom image</button>
|
||||||
{% include 'editcustomimage_modal.html' %}
|
{% include 'editcustomimage_modal.html' %}
|
||||||
|
<script>
|
||||||
|
var editableCustomImageRecipes = {{ custom_image_recipes | objects_to_dictionaries:"id,name" | json }};
|
||||||
|
|
||||||
|
$(document).ready(function () {
|
||||||
|
var editCustomImageTrigger = $('[data-role="edit-custom-image-trigger"]');
|
||||||
|
var editCustomImageModal = $('#edit-custom-image-modal');
|
||||||
|
|
||||||
|
// edit custom image which was built during this build
|
||||||
|
editCustomImageTrigger.click(function () {
|
||||||
|
// single editable custom image: redirect to the edit page
|
||||||
|
// for that image
|
||||||
|
if (editableCustomImageRecipes.length === 1) {
|
||||||
|
var url = '{% url "customrecipe" build.project.id custom_image_recipes.first.id %}';
|
||||||
|
document.location.href = url;
|
||||||
|
}
|
||||||
|
// multiple editable custom images: show modal to select
|
||||||
|
// one of them for editing
|
||||||
|
else {
|
||||||
|
editCustomImageModal.modal('show');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
{% endif %}
|
||||||
|
{% endwith %}
|
||||||
|
|
||||||
|
<!-- new custom image from image recipe in this build -->
|
||||||
|
{% if build.has_image_recipes %}
|
||||||
|
<button class="btn btn-default btn-block navbar-btn" data-role="new-custom-image-trigger">New custom image</button>
|
||||||
|
{% include 'newcustomimage_modal.html' %}
|
||||||
<script>
|
<script>
|
||||||
var editableCustomImageRecipes = {{ custom_image_recipes | objects_to_dictionaries:"id,name" | json }};
|
// imageRecipes includes both custom image recipes and built-in
|
||||||
|
// image recipes, any of which can be used as the basis for a
|
||||||
|
// new custom image
|
||||||
|
var imageRecipes = {{ build.get_image_recipes | objects_to_dictionaries:"id,name" | json }};
|
||||||
|
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
var editCustomImageTrigger = $('[data-role="edit-custom-image-trigger"]');
|
var newCustomImageModal = $('#new-custom-image-modal');
|
||||||
var editCustomImageModal = $('#edit-custom-image-modal');
|
var newCustomImageTrigger = $('[data-role="new-custom-image-trigger"]');
|
||||||
|
|
||||||
// edit custom image which was built during this build
|
// show create new custom image modal to select an image built
|
||||||
editCustomImageTrigger.click(function () {
|
// during this build as the basis for the custom recipe
|
||||||
// single editable custom image: redirect to the edit page
|
newCustomImageTrigger.click(function () {
|
||||||
// for that image
|
if (!imageRecipes.length) {
|
||||||
if (editableCustomImageRecipes.length === 1) {
|
return;
|
||||||
var url = '{% url "customrecipe" build.project.id custom_image_recipes.first.id %}';
|
|
||||||
document.location.href = url;
|
|
||||||
}
|
|
||||||
// multiple editable custom images: show modal to select
|
|
||||||
// one of them for editing
|
|
||||||
else {
|
|
||||||
editCustomImageModal.modal('show');
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
newCustomImageModalSetRecipes(imageRecipes);
|
||||||
|
newCustomImageModal.modal('show');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endwith %}
|
</ul>
|
||||||
|
</div>
|
||||||
<!-- new custom image from image recipe in this build -->
|
<!-- end left sidebar container -->
|
||||||
{% if build.has_image_recipes %}
|
{% endif %}
|
||||||
<button class="btn btn-default btn-block navbar-btn" data-role="new-custom-image-trigger">New custom image</button>
|
|
||||||
{% include 'newcustomimage_modal.html' %}
|
|
||||||
<script>
|
|
||||||
// imageRecipes includes both custom image recipes and built-in
|
|
||||||
// image recipes, any of which can be used as the basis for a
|
|
||||||
// new custom image
|
|
||||||
var imageRecipes = {{ build.get_image_recipes | objects_to_dictionaries:"id,name" | json }};
|
|
||||||
|
|
||||||
$(document).ready(function () {
|
|
||||||
var newCustomImageModal = $('#new-custom-image-modal');
|
|
||||||
var newCustomImageTrigger = $('[data-role="new-custom-image-trigger"]');
|
|
||||||
|
|
||||||
// show create new custom image modal to select an image built
|
|
||||||
// during this build as the basis for the custom recipe
|
|
||||||
newCustomImageTrigger.click(function () {
|
|
||||||
if (!imageRecipes.length) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
newCustomImageModalSetRecipes(imageRecipes);
|
|
||||||
newCustomImageModal.modal('show');
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
{% endif %}
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
|
<!-- right container; need class="row" for builds without left-hand menu -->
|
||||||
|
<div{% if not build.started %} class="row"{% endif %}>
|
||||||
|
{% block buildinfomain %}{% endblock %}
|
||||||
</div>
|
</div>
|
||||||
<!-- end left sidebar container -->
|
|
||||||
|
|
||||||
<!-- begin right container -->
|
|
||||||
{% block buildinfomain %}{% endblock %}
|
|
||||||
<!-- end right container -->
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
{% block buildinfomain %}
|
{% block buildinfomain %}
|
||||||
<!-- page title -->
|
<!-- page title -->
|
||||||
<div class="col-md-10">
|
<div class="{% if build.started %}col-md-10{% else %}col-md-12{% endif %}">
|
||||||
<div class="page-header build-data">
|
<div class="page-header build-data">
|
||||||
<h1>{{build.get_sorted_target_list|field_values:"target"|join:", "}} {{build.machine}}</h1>
|
<h1>{{build.get_sorted_target_list|field_values:"target"|join:", "}} {{build.machine}}</h1>
|
||||||
</div>
|
</div>
|
||||||
|
@ -62,9 +62,9 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-collapse collapse in" id="error-info">
|
<div class="panel-collapse collapse in" id="error-info">
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
<div class="col-md-10">
|
<div class="{% if build.started %}col-md-10{% else %}col-md-12{% endif %}">
|
||||||
{% for error in build.errors %}
|
{% for error in build.errors %}
|
||||||
<div class="alert alert-danger" data-error="{{ error.id }}">
|
<div class="alert alert-danger" data-log-message-id="{{error.pk}}">
|
||||||
<pre>{{error.message}}</pre>
|
<pre>{{error.message}}</pre>
|
||||||
</div>
|
</div>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
@ -201,79 +201,82 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<!-- build summary -->
|
|
||||||
<h2>Build summary</h2>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-4 dashboard-section">
|
|
||||||
<div class="well well-transparent">
|
|
||||||
<h3><a href="{%url 'configuration' build.pk%}">Configuration</a></h3>
|
|
||||||
<dl>
|
|
||||||
<dt>Machine</dt><dd>{{build.machine}}</dd>
|
|
||||||
<dt>Distro</dt><dd>{{build.distro}}</dd>
|
|
||||||
<dt>Layers</dt><dd><ul class="list-unstyled">{% for i in build.layer_version_build.all|dictsort:"layer.name" %}<li>{{i.layer.name}}</li>{%endfor%}</ul></dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="col-md-4 dashboard-section">
|
|
||||||
<div class="well well-transparent">
|
|
||||||
<h3><a href="{%url 'tasks' build.pk%}">Tasks</a></h3>
|
|
||||||
<dl>
|
|
||||||
{% query build.task_build outcome=4 order__gt=0 as exectask%}
|
|
||||||
{% if exectask.count > 0 %}
|
|
||||||
<dt>Failed tasks</dt>
|
|
||||||
<dd>
|
|
||||||
{% if exectask.count == 1 %}
|
|
||||||
<a class="text-danger" href="{% url "task" build.id exectask.0.id %}">
|
|
||||||
{{exectask.0.recipe.name}}
|
|
||||||
<span class="task-name">{{exectask.0.task_name}}</span>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}">
|
{% if build.started %}
|
||||||
<span class="glyphicon glyphicon-download-alt get-help" title="Download task log file"></i>
|
<!-- build summary -->
|
||||||
</a>
|
<h2 data-role="build-summary-heading">Build summary</h2>
|
||||||
|
<div class="row">
|
||||||
{% elif exectask.count > 1%}
|
<div class="col-md-4 dashboard-section">
|
||||||
<a class="text-danger" href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}}</a>
|
<div class="well well-transparent">
|
||||||
{% endif %}
|
<h3><a href="{%url 'configuration' build.pk%}">Configuration</a></h3>
|
||||||
</dd>
|
<dl>
|
||||||
{% endif %}
|
<dt>Machine</dt><dd>{{build.machine}}</dd>
|
||||||
<dt>Total number of tasks</dt><dd><a href="{% url 'tasks' build.pk %}">{% query build.task_build order__gt=0 as alltasks %}{{alltasks.count}}</a></dd>
|
<dt>Distro</dt><dd>{{build.distro}}</dd>
|
||||||
<dt>
|
<dt>Layers</dt><dd><ul class="list-unstyled">{% for i in build.layer_version_build.all|dictsort:"layer.name" %}<li>{{i.layer.name}}</li>{%endfor%}</ul></dd>
|
||||||
Tasks executed
|
</dl>
|
||||||
<span class="glyphicon glyphicon-question-sign get-help" title="'Executed' tasks are those that need to be run in order to generate the task output"></span>
|
</div>
|
||||||
</dt>
|
</div>
|
||||||
<dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A1&count=25&search=&page=1&orderby=order%3A%2B">{% query build.task_build task_executed=1 order__gt=0 as exectask%}{{exectask.count}}</a></dd>
|
<div class="col-md-4 dashboard-section">
|
||||||
<dt>
|
<div class="well well-transparent">
|
||||||
Tasks not executed
|
<h3><a href="{%url 'tasks' build.pk%}">Tasks</a></h3>
|
||||||
<span class="glyphicon glyphicon-question-sign get-help" title="'Not executed' tasks don't need to run because their outcome is provided by another task"></span>
|
<dl>
|
||||||
</dt>
|
{% query build.task_build outcome=4 order__gt=0 as exectask%}
|
||||||
<dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A0&count=25&search=&page=1&orderby=order%3A%2B">{% query build.task_build task_executed=0 order__gt=0 as noexectask%}{{noexectask.count}}</a></dd>
|
{% if exectask.count > 0 %}
|
||||||
<dt>
|
<dt>Failed tasks</dt>
|
||||||
Reuse
|
<dd>
|
||||||
<span class="glyphicon glyphicon-question-sign get-help" title="The percentage of 'not executed' tasks over the total number of tasks, which is a measure of the efficiency of your build"></span>
|
{% if exectask.count == 1 %}
|
||||||
</dt>
|
<a class="text-danger" href="{% url "task" build.id exectask.0.id %}">
|
||||||
<dd>
|
{{exectask.0.recipe.name}}
|
||||||
{% query build.task_build order__gt=0 as texec %}
|
<span class="task-name">{{exectask.0.task_name}}</span>
|
||||||
{% if noexectask.count|multiply:100|divide:texec.count < 0 %}
|
</a>
|
||||||
0
|
|
||||||
{% else %}
|
<a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}">
|
||||||
{{noexectask.count|multiply:100|divide:texec.count}}
|
<span class="glyphicon glyphicon-download-alt get-help" title="Download task log file"></i>
|
||||||
{% endif %}
|
</a>
|
||||||
%
|
|
||||||
</dd>
|
{% elif exectask.count > 1%}
|
||||||
</dl>
|
<a class="text-danger" href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}}</a>
|
||||||
|
{% endif %}
|
||||||
|
</dd>
|
||||||
|
{% endif %}
|
||||||
|
<dt>Total number of tasks</dt><dd><a href="{% url 'tasks' build.pk %}">{% query build.task_build order__gt=0 as alltasks %}{{alltasks.count}}</a></dd>
|
||||||
|
<dt>
|
||||||
|
Tasks executed
|
||||||
|
<span class="glyphicon glyphicon-question-sign get-help" title="'Executed' tasks are those that need to be run in order to generate the task output"></span>
|
||||||
|
</dt>
|
||||||
|
<dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A1&count=25&search=&page=1&orderby=order%3A%2B">{% query build.task_build task_executed=1 order__gt=0 as exectask%}{{exectask.count}}</a></dd>
|
||||||
|
<dt>
|
||||||
|
Tasks not executed
|
||||||
|
<span class="glyphicon glyphicon-question-sign get-help" title="'Not executed' tasks don't need to run because their outcome is provided by another task"></span>
|
||||||
|
</dt>
|
||||||
|
<dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A0&count=25&search=&page=1&orderby=order%3A%2B">{% query build.task_build task_executed=0 order__gt=0 as noexectask%}{{noexectask.count}}</a></dd>
|
||||||
|
<dt>
|
||||||
|
Reuse
|
||||||
|
<span class="glyphicon glyphicon-question-sign get-help" title="The percentage of 'not executed' tasks over the total number of tasks, which is a measure of the efficiency of your build"></span>
|
||||||
|
</dt>
|
||||||
|
<dd>
|
||||||
|
{% query build.task_build order__gt=0 as texec %}
|
||||||
|
{% if noexectask.count|multiply:100|divide:texec.count < 0 %}
|
||||||
|
0
|
||||||
|
{% else %}
|
||||||
|
{{noexectask.count|multiply:100|divide:texec.count}}
|
||||||
|
{% endif %}
|
||||||
|
%
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-4 dashboard-section">
|
||||||
|
<div class="well well-transparent">
|
||||||
|
<h3><a href="{% url 'recipes' build.pk %}">Recipes</a> & <a href="{% url 'packages' build.pk %}">Packages</a></h3>
|
||||||
|
<dl>
|
||||||
|
<dt>Recipes built</dt><dd><a href="{% url 'recipes' build.pk %}">{{recipecount}}</a></dd>
|
||||||
|
<dt>Packages built</dt><dd><a href="{% url 'packages' build.pk %}">{{packagecount}}</a></dd>
|
||||||
|
</dl>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
<div class="col-md-4 dashboard-section">
|
|
||||||
<div class="well well-transparent">
|
|
||||||
<h3><a href="{% url 'recipes' build.pk %}">Recipes</a> & <a href="{% url 'packages' build.pk %}">Packages</a></h3>
|
|
||||||
<dl>
|
|
||||||
<dt>Recipes built</dt><dd><a href="{% url 'recipes' build.pk %}">{{recipecount}}</a></dd>
|
|
||||||
<dt>Packages built</dt><dd><a href="{% url 'packages' build.pk %}">{{packagecount}}</a></dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
{% endif %} <!-- end build summary -->
|
||||||
|
|
||||||
{% if build.warnings.count %}
|
{% if build.warnings.count %}
|
||||||
<div class="panel panel-default" id="warnings">
|
<div class="panel panel-default" id="warnings">
|
||||||
|
@ -285,9 +288,9 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-collapse collapse" id="warning-info">
|
<div class="panel-collapse collapse" id="warning-info">
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
<div class="col-md-10">
|
<div class="{% if build.started %}col-md-10{% else %}col-md-12{% endif %}">
|
||||||
{% for warning in logmessages %}{% if warning.level == 1 %}
|
{% for warning in logmessages %}{% if warning.level == 1 %}
|
||||||
<div class="alert alert-warning">
|
<div class="alert alert-warning" data-log-message-id="{{warning.pk}}">
|
||||||
<pre>{{warning.message}}</pre>
|
<pre>{{warning.message}}</pre>
|
||||||
</div>
|
</div>
|
||||||
{% endif %}{% endfor %}
|
{% endif %}{% endfor %}
|
||||||
|
|
Loading…
Reference in New Issue