Skip to contentSkip to conversation

toaster patchset w/ UI fixes

PATCH In review Alex DAMIAN 2 participants 17 messages Apr 4, 2014 – Apr 7, 2014

lore
Share & tools
lore
#0 lore raw

cover toaster patchset w/ UI fixes

From: Alexandru DAMIAN <[email protected]>

Hello,

Can you please merge this toaster patchest ?
The patches focus on UI fixes, and they have been reviewed on the toaster mailing list.

Thank you,
Alex

The following changes since commit b05e741cb5fe44b37538f2b727782f80dc9bb8fa:

toaster: fix mis-detection of targets as images (2014-04-03 11:33:20 +0100)

are available in the git repository at:

git://git.yoctoproject.org/poky-contrib adamian/20140404-bb-submission
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=adamian/20140404-bb-submission

Alexandru DAMIAN (3):
toaster: do not load all available timezones
toasterui: avoid variable name conflict
toasterui: save warnings from non-build context

Belen Barros Pena (7):
toaster: Update API
toaster: Remove html validation errors in tasks.html
toaster: Changes to help text
toaster: Fix "Recent builds" links
toaster: Fix the empty packages alert
toaster: Make tables happy in Chrome
toaster: Fixes to the build dashboard

David Reyna (2):
toaster: link task order to right tasks page
toaster: catch IndexError error in dictionary lookups

Farrell Wymore (2):
toaster: correct package count
toaster: added covered task list

 lib/bb/ui/buildinfohelper.py                       |  34 +--
 lib/bb/ui/toasterui.py                             |   3 +-
 lib/toaster/bldviewer/api.py                       |   3 +-
 lib/toaster/bldviewer/views.py                     |   3 +-
 lib/toaster/orm/models.py                          |   2 +-
 lib/toaster/toastergui/static/css/default.css      |   6 +-
 lib/toaster/toastergui/static/js/main.js           |   2 +-
 .../toastergui/templates/basebuildpage.html        |   2 +-
 lib/toaster/toastergui/templates/bpackage.html     |  12 +-
 lib/toaster/toastergui/templates/build.html        |   6 +-
 .../toastergui/templates/builddashboard.html       |  57 +++--
 .../templates/package_built_dependencies.html      |   4 +-
 .../toastergui/templates/package_built_detail.html |   6 +-
 .../toastergui/templates/package_detail_base.html  |   4 +-
 .../templates/package_included_dependencies.html   |   2 +-
 .../templates/package_included_tabs.html           |   2 +-
 lib/toaster/toastergui/templates/recipe.html       |  16 +-
 lib/toaster/toastergui/templates/task.html         |  47 +++--
 lib/toaster/toastergui/templates/tasks.html        |  15 +-
 lib/toaster/toastergui/templatetags/projecttags.py |   2 +-
 lib/toaster/toastergui/urls.py                     |   1 +
 lib/toaster/toastergui/views.py                    | 229 +++++++++++++--------
 lib/toaster/toastermain/settings.py                |   8 +-
 23 files changed, 295 insertions(+), 171 deletions(-)
Signature · 1 line
1.9.1
#1 lore raw

PATCH 1/14 toaster: link task order to right tasks page

From: David Reyna <[email protected]>

When linking from a task order number to the All Tasks page, automatically display the correct page for that link anchor.

[YOCTO #5933]

---
 lib/toaster/toastergui/templates/task.html |  2 +-
 lib/toaster/toastergui/urls.py             |  1 +
 lib/toaster/toastergui/views.py            | 36 +++++++++++++++++++++++++-----
 3 files changed, 32 insertions(+), 7 deletions(-)
lib/toaster/toastergui/templates/task.html +1 -1
index 1a7e9d4..5c32250 100644
@@ -199,7 +199,7 @@
         <i class="icon-question-sign get-help" title="The running sequence of each task in the build"></i>
         Task order
     </dt>
-    <dd><a href="{%url "tasks" build.pk %}#{{task.order}}">{{task.order}}</a></dd>
+    <dd><a href="{%url "tasks_task" build.pk task.order %}#{{task.order}}">{{task.order}}</a></dd>
     {% if task.task_executed %}
         <dt>
             <i class="icon-question-sign get-help" title="If this task executes a Python or Shell function(s)"></i>
lib/toaster/toastergui/urls.py +1 -0
index ac83b38..d7e9457 100644
@@ -26,6 +26,7 @@ urlpatterns = patterns('toastergui.views',
         url(r'^build/(?P<build_id>\d+)$', 'builddashboard', name="builddashboard"),
 
         url(r'^build/(?P<build_id>\d+)/tasks/$', 'tasks', name='tasks'),
+        url(r'^build/(?P<build_id>\d+)/tasks/(?P<task_id>\d+)/$', 'tasks_task', name='tasks_task'),
         url(r'^build/(?P<build_id>\d+)/task/(?P<task_id>\d+)$', 'task', name='task'),
 
         url(r'^build/(?P<build_id>\d+)/recipes/$', 'recipes', name='recipes'),
lib/toaster/toastergui/views.py +30 -6
index 05e24ea..a92a03f 100644
@@ -196,7 +196,7 @@ def _get_queryset(model, queryset, filter_string, search_term, ordering_string,
         else:
             queryset = queryset.order_by(column)
 
-    # insure only distinct records (e.g. from multiple search hits) are returned 
+    # insure only distinct records (e.g. from multiple search hits) are returned
     return queryset.distinct()
 
 
@@ -746,7 +746,7 @@ def _find_task_provider(task):
             return trc
     return None
 
-def tasks_common(request, build_id, variant):
+def tasks_common(request, build_id, variant, task_anchor):
 # This class is shared between these pages
 #
 # Column    tasks  buildtime  diskio  cpuusage
@@ -766,6 +766,10 @@ def tasks_common(request, build_id, variant):
 # 'min':on always, 'def':on by default, else hidden
 # '+' default column sort up, '-' default column sort down
 
+    anchor = request.GET.get('anchor', '')
+    if not anchor:
+        anchor=task_anchor
+
     # default ordering depends on variant
     if   'buildtime' == variant:
         title_variant='Time'
@@ -791,12 +795,29 @@ def tasks_common(request, build_id, variant):
     template = 'tasks.html'
     retval = _verify_parameters( request.GET, mandatory_parameters )
     if retval:
+        if task_anchor:
+	        mandatory_parameters['anchor']=task_anchor
         return _redirect_parameters( variant, request.GET, mandatory_parameters, build_id = build_id)
     (filter_string, search_term, ordering_string) = _search_tuple(request, Task)
     queryset_all = Task.objects.filter(build=build_id, order__gt=0)
     queryset_with_search = _get_queryset(Task, queryset_all, None , search_term, ordering_string, 'order')
     queryset = _get_queryset(Task, queryset_all, filter_string, search_term, ordering_string, 'order')
 
+	# compute the anchor's page
+    if anchor:
+	    request.GET = request.GET.copy()
+        del request.GET['anchor']
+        i=0
+        a=int(anchor)
+		count_per_page=int(request.GET.get('count', 100))
+        for task in queryset.iterator():
+            if a == task.order:
+				new_page= (i / count_per_page ) + 1
+				request.GET.__setitem__('page', new_page)
+				mandatory_parameters['page']=new_page
+				return _redirect_parameters( variant, request.GET, mandatory_parameters, build_id = build_id)
+            i += 1
+
     tasks = _build_page_range(Paginator(queryset, request.GET.get('count', 100)),request.GET.get('page', 1))
 
     # define (and modify by variants) the 'tablecols' members
@@ -937,16 +958,19 @@ def tasks_common(request, build_id, variant):
     return render(request, template, context)
 
 def tasks(request, build_id):
-    return tasks_common(request, build_id, 'tasks')
+    return tasks_common(request, build_id, 'tasks', '')
+
+def tasks_task(request, build_id, task_id):
+    return tasks_common(request, build_id, 'tasks', task_id)
 
 def buildtime(request, build_id):
-    return tasks_common(request, build_id, 'buildtime')
+    return tasks_common(request, build_id, 'buildtime', '')
 
 def diskio(request, build_id):
-    return tasks_common(request, build_id, 'diskio')
+    return tasks_common(request, build_id, 'diskio', '')
 
 def cpuusage(request, build_id):
-    return tasks_common(request, build_id, 'cpuusage')
+    return tasks_common(request, build_id, 'cpuusage', '')
 
 
 def recipes(request, build_id):
Signature · 1 line
1.9.1
#2 lore raw

PATCH 2/14 toaster: Update API

From: Belen Barros Pena <[email protected]>

Make sure the REST API includes the latest changes to the database schema.

---
 lib/toaster/bldviewer/api.py   | 3 ++-
 lib/toaster/bldviewer/views.py | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)
lib/toaster/bldviewer/api.py +2 -1
index 76d45c7..c4c6135 100644
@@ -25,12 +25,13 @@ from django.conf.urls import patterns, include, url
 urlpatterns = patterns('bldviewer.views',
         url(r'^builds$', 'model_explorer',  {'model_name':'build'}, name='builds'),
         url(r'^targets$', 'model_explorer',  {'model_name':'target'}, name='targets'),
+        url(r'^target_files$', 'model_explorer',  {'model_name':'target_file'}, name='target_file'),
         url(r'^target_image_file$', 'model_explorer',  {'model_name':'target_image_file'}, name='target_image_file'),
         url(r'^tasks$', 'model_explorer', {'model_name':'task'}, name='task'),
         url(r'^task_dependencies$', 'model_explorer',  {'model_name':'task_dependency'}, name='task_dependencies'),
         url(r'^packages$', 'model_explorer',  {'model_name':'package'}, name='package'),
         url(r'^package_dependencies$', 'model_explorer',  {'model_name':'package_dependency'}, name='package_dependency'),
-        url(r'^target_packages$', 'model_explorer',  {'model_name':'target_package'}, name='target_packages'),
+        url(r'^target_packages$', 'model_explorer',  {'model_name':'target_installed_package'}, name='target_packages'),
         url(r'^target_installed_packages$', 'model_explorer',  {'model_name':'target_installed_package'}, name='target_installed_package'),
         url(r'^package_files$', 'model_explorer',  {'model_name':'build_file'}, name='build_file'),
         url(r'^layers$', 'model_explorer', {'model_name':'layer'}, name='layer'),
lib/toaster/bldviewer/views.py +2 -1
index 6f86379..c2e0c0c 100644
@@ -25,7 +25,7 @@ from django.db.models import Q
 from django.shortcuts import render
 from orm.models import Build, Target, Task, Layer, Layer_Version, Recipe, LogMessage, Variable, Target_Installed_Package
 from orm.models import Task_Dependency, Recipe_Dependency, Package, Package_File, Package_Dependency
-from orm.models import Target_Installed_Package, VariableHistory, Target_Image_File
+from orm.models import Target_Installed_Package, VariableHistory, Target_Image_File, Target_File
 from django.views.decorators.cache import cache_control
 from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
 
@@ -159,6 +159,7 @@ def model_explorer(request, model_name):
     model_mapping = {
         'build': Build,
         'target': Target,
+        'target_file': Target_File,
         'target_image_file': Target_Image_File,
         'task': Task,
         'task_dependency': Task_Dependency,
Signature · 1 line
1.9.1
#3 lore raw

PATCH 3/14 toaster: do not load all available timezones

In reply to Alex DAMIAN

From: Alexandru DAMIAN <[email protected]>

This patch makes sure that we only load pytz-recognized timezones. Pytz is used to transform the timezone information for the database queries, and needs to be able to deal with the TIME_ZONE value that we set up.

[YOCTO #6093]

---
 lib/toaster/toastermain/settings.py | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
lib/toaster/toastermain/settings.py +7 -1
index e26ee3c..e39b4cb 100644
@@ -64,7 +64,13 @@ else:
     for dirpath, dirnames, filenames in os.walk(ZONEINFOPATH):
         for fn in filenames:
             filepath = os.path.join(dirpath, fn)
-            zonefilelist[hashlib.md5(open(filepath).read()).hexdigest()] = filepath.lstrip(ZONEINFOPATH).strip()
+            try:
+                import pytz
+                zonename = filepath.lstrip(ZONEINFOPATH).strip()
+                if pytz.timezone(zonename) is not None:
+                    zonefilelist[hashlib.md5(open(filepath).read()).hexdigest()] = zonename
+            except Exception:
+                pass
 
     TIME_ZONE = zonefilelist[hashlib.md5(open('/etc/localtime').read()).hexdigest()]
 
Signature · 1 line
1.9.1
#4 lore raw

Re: [PATCH 03/14] toaster: do not load all available timezones

Quoted 29 lines · On Friday 04 April 2014 15:10:42 Alex DAMIAN wrote:

From: Alexandru DAMIAN <[email protected]>

This patch makes sure that we only load pytz-recognized timezones. Pytz is used to transform the timezone information for the database queries, and needs to be able to deal with the TIME_ZONE value that we set up.

[YOCTO #6093]

---
 lib/toaster/toastermain/settings.py | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
(quoted diff) +0 -0

b/lib/toaster/toastermain/settings.py index e26ee3c..e39b4cb 100644

lib/toaster/toastermain/settings.py +0 -1
@@ -64,7 +64,13 @@ else:
     for dirpath, dirnames, filenames in os.walk(ZONEINFOPATH):
         for fn in filenames:
             filepath = os.path.join(dirpath, fn)
-            zonefilelist[hashlib.md5(open(filepath).read()).hexdigest()] =

filepath.lstrip(ZONEINFOPATH).strip() + try:

lib/toaster/toastermain/settings.py +4 -0
+                import pytz
+                zonename = filepath.lstrip(ZONEINFOPATH).strip()
+                if pytz.timezone(zonename) is not None:
+                   

zonefilelist[hashlib.md5(open(filepath).read()).hexdigest()] = zonename

lib/toaster/toastermain/settings.py else: · line 73

Quoted 2 lines
lib/toaster/toastermain/settings.py +2 -0
+          except Exception:
+                pass

Please do not do blanket exception catching like this. You need to catch the exact class of exception you expect to receive.

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre
#5 lore raw

Re: [PATCH 03/14] toaster: do not load all available timezones

Thank you for spotting this,

New patch will be sent with the next submission.

Thanks,
Alex

On Fri, Apr 4, 2014 at 4:20 PM, Paul Eggleton <[email protected]

Quoted 48 lines

wrote:

Quoted 19 lines · On Friday 04 April 2014 15:10:42 Alex DAMIAN wrote:

From: Alexandru DAMIAN <[email protected]>

This patch makes sure that we only load pytz-recognized timezones. Pytz is used to transform the timezone information for the database queries, and needs to be able to deal with the TIME_ZONE value that we set up.

[YOCTO #6093]

---
 lib/toaster/toastermain/settings.py | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
(quoted diff) +0 -0

b/lib/toaster/toastermain/settings.py index e26ee3c..e39b4cb 100644

lib/toaster/toastermain/settings.py else: · line 67

Quoted 4 lines
lib/toaster/toastermain/settings.py +0 -1
@@ -64,7 +64,13 @@ else:
     for dirpath, dirnames, filenames in os.walk(ZONEINFOPATH):
         for fn in filenames:
             filepath = os.path.join(dirpath, fn)
-

zonefilelist[hashlib.md5(open(filepath).read()).hexdigest()] =

lib/toaster/toastermain/settings.py else: · line 73

Quoted 8 lines

filepath.lstrip(ZONEINFOPATH).strip() + try:

lib/toaster/toastermain/settings.py +4 -0
+                import pytz
+                zonename = filepath.lstrip(ZONEINFOPATH).strip()
+                if pytz.timezone(zonename) is not None:
+

zonefilelist[hashlib.md5(open(filepath).read()).hexdigest()] = zonename

lib/toaster/toastermain/settings.py +2 -0
+          except Exception:
+                pass

Please do not do blanket exception catching like this. You need to catch the
exact class of exception you expect to receive.

Cheers,
Paul

--

Paul Eggleton
Intel Open Source Technology Centre

Signature · 3 lines
Alex Damian
Yocto Project
SSG / OTC
#6 lore raw

PATCH 4/14 toasterui: avoid variable name conflict

In reply to Alex DAMIAN

From: Alexandru DAMIAN <[email protected]>

We rename a local variable in as to prevent a conflict with a similary named function parameter.

---
 lib/bb/ui/buildinfohelper.py | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
lib/bb/ui/buildinfohelper.py +8 -8
index e4d2f1f..dd93d0b 100644
@@ -761,10 +761,10 @@ class BuildInfoHelper(object):
             recipe_information = self._get_recipe_information_from_taskfile(fn)
             recipe = self.orm_wrapper.get_update_recipe_object(recipe_information)
             class MockEvent: pass
-            event = MockEvent()
-            event.taskname = taskname
-            event.taskhash = taskhash
-            task_information = self._get_task_information(event,recipe)
+            mevent = MockEvent()
+            mevent.taskname = taskname
+            mevent.taskhash = taskhash
+            task_information = self._get_task_information(mevent,recipe)
 
             task_information['start_time'] = datetime.datetime.now()
             task_information['outcome'] = Task.OUTCOME_NA
@@ -780,10 +780,10 @@ class BuildInfoHelper(object):
             recipe_information = self._get_recipe_information_from_taskfile(fn)
             recipe = self.orm_wrapper.get_update_recipe_object(recipe_information)
             class MockEvent: pass
-            event = MockEvent()
-            event.taskname = taskname
-            event.taskhash = taskhash
-            task_information = self._get_task_information(event,recipe)
+            mevent = MockEvent()
+            mevent.taskname = taskname
+            mevent.taskhash = taskhash
+            task_information = self._get_task_information(mevent,recipe)
 
             task_information['path_to_sstate_obj'] = sstatefile
 
Signature · 1 line
1.9.1
#7 lore raw

PATCH 5/14 toasterui: save warnings from non-build context

In reply to Alex DAMIAN

From: Alexandru DAMIAN <[email protected]>

Some warnings and errors may come from a non-build context, and they were not saved, even if they were counted for the current build.

This patch saves these messages in memory until we have the entire build context available.

	[YOCTO #5642]
---
 lib/bb/ui/buildinfohelper.py | 18 +++++++++++++-----
 lib/bb/ui/toasterui.py       |  3 ++-
 2 files changed, 15 insertions(+), 6 deletions(-)
lib/bb/ui/buildinfohelper.py +13 -5
index dd93d0b..6965570 100644
@@ -933,15 +933,23 @@ class BuildInfoHelper(object):
         self._store_log_information(LogMessage.ERROR, text)
 
     def store_log_event(self, event):
-        # look up license files info from insane.bbclass
-        m = re.match("([^:]*): md5 checksum matched for ([^;]*)", event.msg)
-        if m:
-            (pn, fn) = m.groups()
-            self.internal_state['recipes'][pn].save()
+        if 'build' in self.internal_state and 'backlog' in self.internal_state:
+            if len(self.internal_state['backlog']):
+                tempevent = self.internal_state['backlog'].pop()
+                print "Saving stored event ", tempevent
+                self.store_log_event(tempevent)
+            else:
+                del self.internal_state['backlog']
 
         if event.levelno < format.WARNING:
             return
+
         if not 'build' in self.internal_state:
+            print "Save event for later"
+            if not 'backlog' in self.internal_state:
+                self.internal_state['backlog'] = []
+            self.internal_state['backlog'].append(event)
+
             return
         log_information = {}
         log_information['build'] = self.internal_state['build']
lib/bb/ui/toasterui.py +2 -1
index 37d6b1a..9a9fe6f 100644
@@ -143,6 +143,8 @@ def main(server, eventHandler, params ):
 
             # these events are unprocessed now, but may be used in the future to log
             # timing and error informations from the parsing phase in Toaster
+            if isinstance(event, (bb.event.SanityCheckPassed, bb.event.SanityCheck)):
+                continue
             if isinstance(event, bb.event.ParseStarted):
                 continue
             if isinstance(event, bb.event.ParseProgress):
@@ -209,7 +211,6 @@ def main(server, eventHandler, params ):
                 continue
 
             if isinstance(event, (bb.event.BuildCompleted)):
-                buildinfohelper.update_build_information(event, errors, warnings, taskfailures)
                 continue
 
             if isinstance(event, (bb.command.CommandCompleted,
Signature · 1 line
1.9.1
#8 lore raw

PATCH 6/14 toaster: Remove html validation errors in tasks.html

In reply to Alex DAMIAN

From: Belen Barros Pena <[email protected]>

Remove the duplicated class attribute and the name attribute.

Also, make sure that the row blue highlight works
without the name attribute when you land on the
tasks table after clicking the order link in a
task details page.

The commit also fixes a typo in default.css.

[YOCTO #6033]

---
 lib/toaster/toastergui/static/css/default.css |  2 +-
 lib/toaster/toastergui/static/js/main.js      |  2 +-
 lib/toaster/toastergui/templates/tasks.html   | 15 ++++++++++++++-
 3 files changed, 16 insertions(+), 3 deletions(-)
lib/toaster/toastergui/static/css/default.css +1 -1
index 0b53718..b4345da 100644
@@ -103,7 +103,7 @@ select { width: auto; }
 .well > .lead, .alert .lead { margin-bottom: 0px; }
 .no-results { margin: 10px 0; }
 .task-name { margin-left: 7px; }
-.icon-hand-right {color: #ccccc; }
+.icon-hand-right {color: #CCCCCC; }
 .help-inline { margin: 5px; }
 .hero-unit { margin: 20px 0 30px; }
 .hero-unit > .close { font-size:40px; }
lib/toaster/toastergui/static/js/main.js +1 -1
index 7f897d2..eef6b46 100644
@@ -107,5 +107,5 @@ $(document).ready(function() {
     if (location.href.search('#warnings') > -1) {
         $('#collapse-warnings').addClass('in');
     }
-
+        
 });
lib/toaster/toastergui/templates/tasks.html +14 -1
index d68a31a..77d38b0 100644
@@ -75,7 +75,7 @@
   {% include "basetable_top.html" %}
 
     {% for task in objects %}
-        <tr {{ task|task_color }} class="flash" id="{{task.order}}" name="{{task.order}}">
+        <tr {{ task|task_color }} id="{{task.order}}">
             <td class="order">
                 <a href="{%url "task" build.pk task.pk%}">{{task.order}}</a>
             </td>
@@ -117,4 +117,17 @@
   {% endif %} {# objects.paginator.count #}
 {% endif %} {# empty #}
 </div>
+
+<script type="text/javascript">
+
+    $(document).ready(function() {
+        // enable blue hightlight animation for the order link
+        if (location.href.search('#') > -1) {
+            var task_order = location.href.split('#')[1];
+            $("#" + task_order).addClass("highlight"); 
+        }
+    });
+    
+</script>
+
 {% endblock %}
Signature · 1 line
1.9.1
#9 lore raw

PATCH 7/14 toaster: Changes to help text

In reply to Alex DAMIAN

From: Belen Barros Pena <[email protected]>

All help text strings have been reviewed by the technical writer, and some of them by Paul Eggleton. This patch implements their suggested changes.

---
 lib/toaster/orm/models.py                          |  2 +-
 .../toastergui/templates/builddashboard.html       | 20 +++++++--
 .../templates/package_built_dependencies.html      |  4 +-
 .../toastergui/templates/package_built_detail.html |  6 +--
 .../toastergui/templates/package_detail_base.html  |  4 +-
 .../templates/package_included_dependencies.html   |  2 +-
 .../templates/package_included_tabs.html           |  2 +-
 lib/toaster/toastergui/templates/recipe.html       | 16 +++----
 lib/toaster/toastergui/templates/task.html         | 34 +++++++-------
 lib/toaster/toastergui/views.py                    | 52 +++++++++++-----------
 10 files changed, 77 insertions(+), 65 deletions(-)
lib/toaster/orm/models.py +1 -1
index 658e1d2..c344c66 100644
@@ -150,7 +150,7 @@ class Task(models.Model):
     )
 
     TASK_OUTCOME_HELP = (
-        (OUTCOME_SUCCESS, 'This task completed successfully'),
+        (OUTCOME_SUCCESS, 'This task successfully completed'),
         (OUTCOME_COVERED, 'This task did not run because its output is provided by another task'),
         (OUTCOME_CACHED, 'This task restored output from the sstate-cache directory or mirrors'),
         (OUTCOME_PREBUILT, 'This task did not run because its outcome was reused from a previous build'),
lib/toaster/toastergui/templates/builddashboard.html +16 -4
index 6563128..6cce788 100644
@@ -84,7 +84,7 @@
 			<dt>Total package size</dt>
 			<dd>{{target.pkgsz|filtered_filesizeformat}}</dd>
 			<dt>
-				<i class="icon-question-sign get-help" title="The location in disk of the license manifest, a document listing all packages installed in your image and their licenses"></i>
+				<i class="icon-question-sign get-help" title="Path to the license manifest, which is a document listing all packages installed in your image and their licenses"></i>
 				License manifest
 			</dt>
 			<dd><a href="{% url 'targetpackages' build.pk target.target.pk %}"><code>{{target.target.license_manifest_path}}</code></a></dd>
@@ -126,9 +126,21 @@
         <h4><a href="{%url 'tasks' build.pk%}">Tasks</a></h4>
             <dl>
         <dt>Total number of tasks</dt><dd><a href="{% url 'tasks' build.pk %}">{{build.task_build.all.count}}</a></dd>
-        <dt>Tasks executed</dt><dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A1&amp;count=25&amp;search=&amp;page=1&amp;orderby=order%3A%2B">{% query build.task_build task_executed=1 order__gt=0 as exectask%}{{exectask.count}}</a></dd>
-        <dt>Tasks not executed</dt><dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A0&amp;count=25&amp;search=&amp;page=1&amp;orderby=order%3A%2B">{% query build.task_build task_executed=0 order__gt=0 as noexectask%}{{noexectask.count}}</a></dd>
-        <dt>Reuse</dt><dd>
+        <dt>
+            Tasks executed
+            <i class="icon-question-sign get-help" title="'Executed' tasks are those that need to be run in order to generate the task output"></i>
+        </dt>
+        <dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A1&amp;count=25&amp;search=&amp;page=1&amp;orderby=order%3A%2B">{% query build.task_build task_executed=1 order__gt=0 as exectask%}{{exectask.count}}</a></dd>
+        <dt>
+            Tasks not executed
+            <i class="icon-question-sign get-help" title="'Not executed' tasks don't need to run because their outcome is provided by another task"></i>
+        </dt>           
+        <dd><a href="{% url 'tasks' build.pk %}?filter=task_executed%3A0&amp;count=25&amp;search=&amp;page=1&amp;orderby=order%3A%2B">{% query build.task_build task_executed=0 order__gt=0 as noexectask%}{{noexectask.count}}</a></dd>
+        <dt>
+            Reuse
+            <i class="icon-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"></i>
+        </dt>     
+        <dd>
 {% query build.task_build order__gt=0 as texec %}
 {% if noexectask.count|multiply:100|divide:texec.count < 0 %}
 0
lib/toaster/toastergui/templates/package_built_dependencies.html +2 -2
index 8613f1e..4e86da5 100644
@@ -24,7 +24,7 @@
                 </div>
             {% else %}
                 <div class="alert alert-info">
-                    <strong>{{package.fullpackagespec}}</strong> is <strong>not included</strong> in any image.  These are its projected runtime dependencies if you were to include it in future builds.
+                    <strong>{{package.fullpackagespec}}</strong> is <strong>not included</strong> in any image. This page shows you the projected runtime dependencies if you include <strong>{{package.fullpackagespec}}</strong> in future builds.
                 </div>
                 <table class="table table-bordered table-hover">
                     <thead>
@@ -64,7 +64,7 @@
                             <th>Version</th>
                             <th>Size</th>
                             <th>
-                                <i class="icon-question-sign get-help" title="There are 5 relationship types: recommends, suggests, provides, replaces and conflicts"></i>
+                                <i class="icon-question-sign get-help" title="Five relationship types exist: recommends, suggests, provides, replaces and conflicts"></i>
                                 Relationship type
                             </th>
                         </tr>
lib/toaster/toastergui/templates/package_built_detail.html +3 -3
index 6ccd405..3aa1b2a 100644
@@ -8,11 +8,11 @@
             {# Not included case #}
             <ul class="nav nav-pills">
                 <li class="active"> <a href="#">
-                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Files that would be added to a root file system if you were to include {{package.name}} in an image"></i>
+                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Files added to a root file system when you include {{package.name}} in an image"></i>
                     Generated files ({{packageFileCount}})
                 </a></li>
                 <li class=""><a href="{% url 'package_built_dependencies' build.id package.id %}">
-                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Projected runtime dependencies if you were to include {{package.name}} in an image"></i>
+                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Projected runtime dependencies when you include {{package.name}} in an image"></i>
                     Runtime dependencies ({{dependency_count}})
                 </a></li>
             </ul>
@@ -21,7 +21,7 @@
             <!-- Package file list or if empty, alert pane -->
             {% if packageFileCount > 0 %}
                 <div class="alert alert-info">
-                    {{package.fullpackagespec}} is <strong>not included</strong> in any image.  These are the files that would be added to an image root file system if you were to include it in future builds.
+                    <strong>{{package.fullpackagespec}}</strong> is <strong>not included</strong> in any image. This page shows you the files added to an image root file system if you include <strong>{{package.fullpackagespec}}</strong> in future builds.
                 </div>
                 <table class="table table-bordered table-hover">
                     <thead>
lib/toaster/toastergui/templates/package_detail_base.html +2 -2
index 5ec9dd7..5888513 100644
@@ -83,7 +83,7 @@
             # problemse are resolved.
             <dt>
                 License files
-                <i class="icon-question-sign get-help" data-toggle="tooltip" title="Location in disk of the license files that apply to the package"></i>
+                <i class="icon-question-sign get-help" data-toggle="tooltip" title="Path to the license files that apply to the package"></i>
             </dt>
             <dd></dd>
             {% endcomment %}
@@ -136,7 +136,7 @@
             <dd class="iscommit">{{package.recipe.layer_version.commit}}</dd>
             <dt>
                 Layer directory
-                <i class="icon-question-sign get-help" data-toggle="tooltip" title="Location in disk of the layer providing the recipe that builds this package"></i>
+                <i class="icon-question-sign get-help" data-toggle="tooltip" title="Path to the layer providing the recipe that builds this package"></i>
             </dt>
             <dd><code>{{package.recipe.layer_version.layer.local_path}}</code></dd>
         </dl>
lib/toaster/toastergui/templates/package_included_dependencies.html +1 -1
index e06e073..9169ee9 100644
@@ -59,7 +59,7 @@
                         <th>Version</th>
                         <th>Size</th>
                         <th>
-                            <i class="icon-question-sign get-help" title="There are 5 relationship types: recommends, suggests, provides, replaces and conflicts"></i>
+                            <i class="icon-question-sign get-help" title="Five relationship types exist: recommends, suggests, provides, replaces and conflicts"></i>
                             Relationship type
                         </th>
                     </tr>
lib/toaster/toastergui/templates/package_included_tabs.html +1 -1
index 3ea4915..0140b03 100644
@@ -26,7 +26,7 @@
         <li class="">
     {% endif %}
             <a href="{% url 'package_included_reverse_dependencies' build.id target.id package.id %}">
-                <i class="icon-question-sign get-help" data-toggle="tooltip" title="The package runtime reverse dependencies (i.e. which other packages in this image depend on this package). Reverse dependencies reflect only the 'depends' dependency type"></i>
+                <i class="icon-question-sign get-help" data-toggle="tooltip" title="The package runtime reverse dependencies (i.e. the packages in this image that depend on this package). Reverse dependencies reflect only the 'depends' dependency type"></i>
                 Reverse runtime dependencies ({{reverse_count}})
             </a>
         </li>
lib/toaster/toastergui/templates/recipe.html +8 -8
index b8898d2..c846aa9 100644
@@ -33,13 +33,13 @@
         </li>
         <li>
             <a href="#dependencies" data-toggle="tab">
-                <i class="icon-question-sign get-help" data-toggle="tooltip" title="The recipe build-time dependencies (other recipes)"></i>
+                <i class="icon-question-sign get-help" data-toggle="tooltip" title="The recipe build-time dependencies (i.e. other recipes)"></i>
                 Build dependencies ({{object.r_dependencies_recipe.all.count}})
             </a>
         </li>
         <li>
             <a href="#brought-in-by" data-toggle="tab">
-                <i class="icon-question-sign get-help" data-toggle="tooltip" title="The recipe build-time reverse dependencies (i.e. which other recipes depend on this recipe)"></i>
+                <i class="icon-question-sign get-help" data-toggle="tooltip" title="The recipe build-time reverse dependencies (i.e. the recipes that depend on this recipe)"></i>
                 Reverse build dependencies ({{object.r_dependencies_depends.all.count}})
             </a>
         </li>
@@ -53,12 +53,12 @@
                 </dt>
                 <dd>{{layer.name}}</dd>
                 <dt>
-                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Location in disk of the layer providing the recipe"></i>
+                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Path to the layer providing the recipe"></i>
                     Layer directory
                 </dt>
                 <dd><code>{{layer.local_path}}</code></dd>
                 <dt>
-                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Location in disk of the recipe .bb file"></i>
+                    <i class="icon-question-sign get-help" data-toggle="tooltip" title="Path to the recipe .bb file"></i>
                     Recipe file
                 </dt>
                 <dd><code>{{object.file_path}}</code></dd>
@@ -91,15 +91,15 @@
                         Task
                     </th>
                     <th>
-                        <i class="icon-question-sign get-help" title="This value tells you if a task had to run in order to generate the task output (executed), or if the output was provided by another task and therefore the task didn't need to run (not executed)"></i>
+                        <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>
                         Executed
                     </th>
                     <th>
-                        <i class="icon-question-sign get-help" title="This column tells you if executed tasks succeeded, failed or reused output from the sstate-cache directory or mirrors. It also tells you why not executed tasks did not need to run"></i>
+                        <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>
                         Outcome
                     </th>
                     <th>
-                        <i class="icon-question-sign get-help" title="This column tells you if a task tried to restore output from the <code>sstate-cache</code> directory or mirros, and what was the result: Succeeded, Failed or File not in cache"></i>
+                        <i class="icon-question-sign get-help" title="This column tells you if a task tried to restore output from the <code>sstate-cache</code> directory or mirrors, and reports the result: Succeeded, Failed or File not in cache"></i>
                         Cache attempt
                     </th>
                 </thead>
@@ -259,7 +259,7 @@
         {% if object.section %}
             <dt>
             Section
-            <i class="icon-question-sign get-help" data-toggle="tooltip" title="The section in which recipes should be categorised"></i>
+            <i class="icon-question-sign get-help" data-toggle="tooltip" title="The section in which recipes should be categorized"></i>
             </dt>
             <dd>{{object.section}}</dd>
         {% endif %}
lib/toaster/toastergui/templates/task.html +17 -17
index 5c32250..c1504b6 100644
@@ -25,7 +25,7 @@
     <dl class="dl-horizontal">
 	{% if task.logfile %}
         <dt>
-            <i class="icon-question-sign get-help" title="The location in disk of the task log file"></i> Log file
+            <i class="icon-question-sign get-help" title="Path the task log file"></i> Log file
         </dt>
         <dd>
             <code>{{task.logfile}}</code>
@@ -46,10 +46,10 @@
 {# not executed tasks outcome #}
     {% if task.outcome == task.OUTCOME_PREBUILT %}
         {% if not showing_matches %}
-            <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 will show you a list of tasks from previous builds with the same inputs signature as this prebuilt task. Any of them could be the task that generated the output this prebuilt task is reusing"></i></a>
+            <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>
         {% elif matching_tasks %}
             <h3 class="details">Prebuilt task could be based on
-                <i class="icon-question-sign get-help heading-help" title="This table shows a list of tasks from previous builds with the same inputs signature as the prebuilt task. Any of them could be the task that generated the output the prebuilt task is reusing"></i>
+                <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>
             </h3>
             <table class="table table-bordered table-hover">
                 <thead>
@@ -62,11 +62,11 @@
                         Task
                     </th>
                     <th>
-                        <i class="icon-question-sign get-help" title="This value tells you if a task had to run in order to generate the task output (executed), or if the output was provided by another task and therefore the task didn't need to run (not executed)"></i>
+                        <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>
                         Executed
                     </th>
                     <th>
-                        <i class="icon-question-sign get-help" title="This column tells you if executed tasks succeeded, failed or reused output from the sstate-cache directory or mirrors. It also tells you why not executed tasks did not need to run"></i>
+                        <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>
                         Outcome
                     </th>
                     <th>
@@ -116,7 +116,7 @@
     {%elif task.outcome == task.OUTCOME_CACHED%}
         <dl class="dl-horizontal">
             <dt>
-                <i class="icon-question-sign get-help" title="The location in disk of the task log file"></i> Log file
+                <i class="icon-question-sign get-help" title="Path the task log file"></i> Log file
             </dt>
             <dd>
                 <code>{% for t in task.get_related_setscene %} {{t.logfile}} {% endfor %}</code>
@@ -133,11 +133,11 @@
     {% if task.task_executed %}
 	<h2>
         Executed
-        <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>
+        <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>
     {% else %}
 	<h2 class="muted">
         Not Executed
-        <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>
+        <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>
     {% endif %}
 	</h2>
 <dl class="dl-horizontal">
@@ -151,7 +151,7 @@
     {% if task.sstate_result != task.SSTATE_NA %}
 		</dl>
         <div class="alert alert-info">Attempting to restore output from sstate cache
-            <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 it finds it, it will use it instead of building it from scratch by running the real task. This makes the build faster"></i>
+            <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>
         </div>
 		<dl class="dl-horizontal">
             <dt>
@@ -160,7 +160,7 @@
             </dt>
             <dd><code>{{task.path_to_sstate_obj}}</code></dd>
             <dt>
-                <i class="icon-question-sign get-help" title="The locations where the above file was searched: your <code>sstate-cache</code> directory and the mirrors you have set up (if any)"></i>
+                <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>
                 URI(s) searched
             </dt>
             <dd><code>{{task.work_directory}}</code></dd>
@@ -176,12 +176,12 @@
         </div>
         <dl class="dl-horizontal">
             <dt>
-                <i class="icon-question-sign get-help" title="The location in disk of the cache attempt log file"></i>
+                <i class="icon-question-sign get-help" title="Path to the cache attempt log file"></i>
                 Log file
             </dt>
             <dd><code>{{task.logfile}}</code></dd>
             <dt>
-                <i class="icon-question-sign get-help" title="How long it took the cache attempt to finish, expressed in seconds"></i>
+                <i class="icon-question-sign get-help" title="How long it took the cache attempt to finish in seconds"></i>
                 Time (secs)
             </dt>
             <dd>{{task.elapsed_time|format_none_and_zero}}</dd>
@@ -202,7 +202,7 @@
     <dd><a href="{%url "tasks_task" build.pk task.order %}#{{task.order}}">{{task.order}}</a></dd>
     {% if task.task_executed %}
         <dt>
-            <i class="icon-question-sign get-help" title="If this task executes a Python or Shell function(s)"></i>
+            <i class="icon-question-sign get-help" title="Indicates if this task executes a Python or Shell function(s)"></i>
             Task script type
         </dt>
         <dd>{{task.get_script_type_display}}</dd>
@@ -215,7 +215,7 @@
     <dd><code>{{task.source_url}}</code></dd>
 -->
     <dt>
-        <i class="icon-question-sign get-help" title="Task dependency chain (other tasks)"></i>
+        <i class="icon-question-sign get-help" title="Task dependency chain (i.e. other tasks)"></i>
         Dependencies
     </dt>
     <dd>
@@ -228,7 +228,7 @@
         </ul>
     </dd>
     <dt>
-        <i class="icon-question-sign get-help" title="Which other tasks depend on this task"></i>
+        <i class="icon-question-sign get-help" title="Tasks that depend on this task"></i>
         Reverse dependencies
     </dt>
     <dd>
@@ -248,14 +248,14 @@
     <dl class="dl-horizontal">
 		{% if task.elapsed_time %}
         <dt>
-            <i class="icon-question-sign get-help" title="How long it took the task to finish, expressed in seconds"></i>
+            <i class="icon-question-sign get-help" title="How long it took the task to finish in seconds"></i>
             Time (secs)
         </dt>
         <dd>{{task.elapsed_time|format_none_and_zero|floatformat:2}}</dd>
 		{% endif %}	
 		{% if task.cpu_usage > 0 %}	
         <dt>
-            <i class="icon-question-sign get-help" title="Task CPU utilisation, expressed as a percentage"></i>
+            <i class="icon-question-sign get-help" title="The percentage of task CPU utilization"></i>
             CPU usage
         </dt>
         <dd>{{task.cpu_usage|format_none_and_zero|floatformat:2}}%</dd>
lib/toaster/toastergui/views.py +26 -26

189 lines not on this page · raw message

Signature · 1 line
1.9.1
#10 lore raw

PATCH 8/14 toaster: catch IndexError error in dictionary lookups

In reply to Alex DAMIAN

From: David Reyna <[email protected]>

In the get_dict_value filter, there is the edge case where halted builds can lead to IndexError errors in dictionary lookups, so we need to catch those.

[YOCTO #6067]

---
 lib/toaster/toastergui/templatetags/projecttags.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/toaster/toastergui/templatetags/projecttags.py +1 -1
index 3dd0f3d..ee08ab7 100644
@@ -247,5 +247,5 @@ def get_dict_value(dictionary, key):
     """
     try:
         return dictionary[key]
-    except KeyError:
+    except (KeyError, IndexError):
         return ''
Signature · 1 line
1.9.1
#11 lore raw

PATCH 9/14 toaster: Fix "Recent builds" links

In reply to Alex DAMIAN

From: Belen Barros Pena <[email protected]>

* Link the number of errors to the #errors section in the build dashboard

* Link the number of warnigns to the #warnings section in the build dashboard

* Link the build time to the build time page

* Move some javascript that applies only to builddashboard.html to that template from main.js

---
 lib/toaster/toastergui/templates/build.html          | 6 +++---
 lib/toaster/toastergui/templates/builddashboard.html | 9 +++++++++
 2 files changed, 12 insertions(+), 3 deletions(-)
lib/toaster/toastergui/templates/build.html +3 -3
index afa390f..faabd22 100644
@@ -48,16 +48,16 @@
     {%if build.outcome == build.SUCCEEDED or build.outcome == build.FAILED %}
             <div class="span2 lead">
     {% if  build.errors_no %}
-                <i class="icon-minus-sign red"></i> <a href="{%url 'builddashboard' build.pk%}" class="error">{{build.errors_no}} error{{build.errors_no|pluralize}}</a>
+                <i class="icon-minus-sign red"></i> <a href="{%url 'builddashboard' build.pk%}#errors" class="error">{{build.errors_no}} error{{build.errors_no|pluralize}}</a>
     {% endif %}
             </div>
             <div class="span2 lead">
     {% if  build.warnings_no %}
-                <i class="icon-warning-sign yellow"></i> <a href="{%url 'builddashboard' build.pk%}" class="warning">{{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a>
+                <i class="icon-warning-sign yellow"></i> <a href="{%url 'builddashboard' build.pk%}#warnings" class="warning">{{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a>
     {% endif %}
             </div>
             <div class="lead pull-right">
-                Build time: <a href="build-time.html">{{ build.timespent|sectohms }}</a>
+                Build time: <a href="{% url 'buildtime' build.pk %}">{{ build.timespent|sectohms }}</a>
             </div>
     {%endif%}{%if build.outcome == build.IN_PROGRESS %}
             <div class="span4">
lib/toaster/toastergui/templates/builddashboard.html +9 -0
index 6cce788..cc92af5 100644
@@ -186,4 +186,13 @@
 </div>
 {% endif %}
 
+<script type="text/javascript">
+    $(document).ready(function() {
+        //show warnings section when requested from the previous page
+        if (location.href.search('#warnings') > -1) {
+            $('#collapse-warnings').addClass('in');
+        }
+    });
+</script>
+
 {% endblock %}
Signature · 1 line
1.9.1
#12 lore raw

PATCH 10/14 toaster: Fix the empty packages alert

In reply to Alex DAMIAN

From: Belen Barros Pena <[email protected]>

* Remove a tag in all capitals
* Remove an unnecessary div
* Fix a typo

---
 lib/toaster/toastergui/templates/bpackage.html | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)
lib/toaster/toastergui/templates/bpackage.html +5 -7
index 22609e2..c6ec634 100644
@@ -17,16 +17,14 @@
 
 <!-- Empty - no data in database -->
 <div class="page-header">
-  <div class="page-header">
     <h1>
-    Packages
+        Packages
     </h1>
-    </div>
-  <div class="alert alert-info lead">
-    <STRONG>No packages were built.</STRONG> How did this happen? Well, BitBake reuses as much stuff as possible.
-    If all of the packages needed were already built and available in your build infrastructure, Bitbake
+</div>
+<div class="alert alert-info lead">
+    <strong>No packages were built.</strong> How did this happen? Well, BitBake reuses as much stuff as possible.
+    If all of the packages needed were already built and available in your build infrastructure, BitBake
     will not rebuild any of them. This might be slightly confusing, but it does make everything faster.
-  </div>
 </div>
 
 {% else %}
Signature · 1 line
1.9.1
#13 lore raw

PATCH 11/14 toaster: Make tables happy in Chrome

In reply to Alex DAMIAN

From: Belen Barros Pena <[email protected]>

There is a known layout issue with Bootstrap tables in Chrome. This change applies a css fix for it, and changes the span classes in the variables table to improve formatting.

---
 lib/toaster/toastergui/static/css/default.css | 3 +++
 lib/toaster/toastergui/views.py               | 4 +---
 2 files changed, 4 insertions(+), 3 deletions(-)
lib/toaster/toastergui/static/css/default.css +3 -0
index b4345da..baf70fb 100644
@@ -109,6 +109,9 @@ select { width: auto; }
 .hero-unit > .close { font-size:40px; }
 .hero-actions { margin-top: 30px; }
 
+/* make tables Chrome-happy (me, not so much) */
+#otable { table-layout: fixed; word-wrap: break-word; }
+
 
 
 
lib/toaster/toastergui/views.py +1 -3
index ba69dd8..e346ac4 100644
@@ -1142,7 +1142,6 @@ def configvars(request, build_id):
                 'tablecols' : [
                 {'name': 'Variable',
                  'qhelp': "BitBake is a generic task executor that considers a list of tasks with dependencies and handles metadata that consists of variables in a certain format that get passed to the tasks",
-                 'dclass' : "span3",
                  'orderfield': _get_toggle_order(request, "variable_name"),
                  'ordericon':_get_toggle_order_icon(request, "variable_name"),
                 },
@@ -1153,7 +1152,6 @@ def configvars(request, build_id):
                 {'name': 'Set in file',
                  'qhelp': "The last configuration file that touched the variable value",
                  'clclass': 'file', 'hidden' : 0,
-                 'dclass': "span6",
                  'filter' : {
                     'class' : 'vhistory__file_name',
                     'label': 'Show:',
@@ -1169,7 +1167,7 @@ def configvars(request, build_id):
                 {'name': 'Description',
                  'qhelp': "A brief explanation of the variable",
                  'clclass': 'description', 'hidden' : 0,
-                 'dclass': "span5",
+                 'dclass': "span4",
                  'filter' : {
                     'class' : 'description',
                     'label': 'Show:',
Signature · 1 line
1.9.1
#14 lore raw

PATCH 12/14 toaster: Fixes to the build dashboard

In reply to Alex DAMIAN

From: Belen Barros Pena <[email protected]>

* Add "on" before the date in the build status

* Get rid of the extra space before the "and" in the build status

* Make the errors and warnings links in the build
status show the message content

* Make sure that the "Images" section in the left navigation appears only for successful builds

* Link the number of packages installed to the "Packages included" tab in the image information page

* Remove unnecessary inline styles in the dashboard template

* Make sure target names in the h1 are listed in
alphabetical order

---
 lib/toaster/toastergui/static/css/default.css      |  1 +
 .../toastergui/templates/basebuildpage.html        |  2 +-
 .../toastergui/templates/builddashboard.html       | 30 +++++++++++-----------
 3 files changed, 17 insertions(+), 16 deletions(-)
lib/toaster/toastergui/static/css/default.css +1 -0
index baf70fb..e33f177 100644
@@ -108,6 +108,7 @@ select { width: auto; }
 .hero-unit { margin: 20px 0 30px; }
 .hero-unit > .close { font-size:40px; }
 .hero-actions { margin-top: 30px; }
+.dashboard-section { background-color: transparent; }
 
 /* make tables Chrome-happy (me, not so much) */
 #otable { table-layout: fixed; word-wrap: break-word; }
lib/toaster/toastergui/templates/basebuildpage.html +1 -1
index 778c4d4..4611051 100644
@@ -32,7 +32,7 @@
         <!-- begin left sidebar container -->
         <div id="nav" class="span2">
             <ul class="nav nav-list well">
-              {% if build.target_set.all.0.is_image %}
+              {% if build.target_set.all.0.is_image and build.outcome == 0 %}
                 <li class="nav-header">Images</li>
                 {% block nav-target %}
                   {% for t in build.get_sorted_target_list %}
lib/toaster/toastergui/templates/builddashboard.html +15 -15
index cc92af5..891d860 100644
@@ -10,7 +10,7 @@
 <!-- page title -->
 <div class="row-fluid span10">
  <div class="page-header">
-     <h1>{{build.target_set.all|join:", "}} {{build.machine}}</h1>
+     <h1>{{build.target_set.all|dictsort:"target"|join:", "}} {{build.machine}}</h1>
  </div>
 </div>
 
@@ -20,7 +20,7 @@
     <div class="row-fluid lead">
             <span class="pull-left"><strong>
                 {%if build.outcome == build.SUCCEEDED%}Completed{%elif build.outcome == build.FAILED%}Failed{%else%}{%endif%}
-              </strong>
+              </strong> on
             {{build.completed_on|date:"d/m/y H:i"}}
 </span>
 {% if  build.warnings_no or build.errors_no %}
@@ -28,13 +28,13 @@
 {% endif %}
 {%if build.outcome == build.SUCCEEDED or build.outcome == build.FAILED %}
 {% if  build.errors_no %}
-     <span > <i class="icon-minus-sign red"></i><strong><a href="#errors" class="error"> {{build.errors_no}} error{{build.errors_no|pluralize}}</a></strong></span>
+     <span > <i class="icon-minus-sign red"></i><strong><a href="#errors" class="error show-errors"> {{build.errors_no}} error{{build.errors_no|pluralize}}</a></strong></span>
 {% endif %}
 {% if  build.warnings_no %}
 {% if  build.errors_no %}
-&nbsp;and
+    and
 {% endif %}
-    <span > <i class="icon-warning-sign yellow"></i><strong><a href="#warnings" class="warning"> {{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a></strong></span>
+    <span > <i class="icon-warning-sign yellow"></i><strong><a href="#warnings" class="warning show-warnings"> {{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a></strong></span>
 {% endif %}
             <span class="pull-right">Build time: <a href="{% url 'buildtime' build.pk %}">{{ build.timespent|sectohms }}</a></span>
 {%endif%}
@@ -75,27 +75,27 @@
 	<h2>Images</h2>
 	{% for target in targets %}
         {% if target.target.is_image %}
-	<div class="well" style="background-color:transparent;">
+	<div class="well dashboard-section">
 		<h3><a href="{% url 'target' build.pk target.target.pk %}">{{target.target}}</a>
                 </h3>
 		<dl class="dl-horizontal">
 			<dt>Packages included</dt>
-			<dd><a href="{% url 'packages' build.pk %}">{{target.npkg}}</a></dd>
+			<dd><a href="{% url 'target' build.pk target.target.pk %}">{{target.npkg}}</a></dd>
 			<dt>Total package size</dt>
 			<dd>{{target.pkgsz|filtered_filesizeformat}}</dd>
 			<dt>
-				<i class="icon-question-sign get-help" title="Path to the license manifest, which is a document listing all packages installed in your image and their licenses"></i>
-				License manifest
+				<i class="icon-question-sign get-help" title="The location in disk of the license manifest, a document listing all packages installed in your image and their licenses"></i>
+				<a href="{% url 'target' build.pk target.target.pk %}">License manifest</a>
 			</dt>
-			<dd><a href="{% url 'targetpackages' build.pk target.target.pk %}"><code>{{target.target.license_manifest_path}}</code></a></dd>
+			<dd><code>{{target.target.license_manifest_path}}</code></dd>
 			<dt>
-				<i class="icon-question-sign get-help" title="Image files are stored in <code style='background-color:transparent;color:#FFFFFF;font-weight:normal;border:none;'>/build/tmp/deploy/images/</code>"></i>
+				<i class="icon-question-sign get-help" title="Image files are stored in <code>/build/tmp/deploy/images/</code>"></i>
 				Image files
 			</dt>
 			<dd>
 				<ul>
                                   {% for i in target.imageFiles %}
-					<li><strong>{{i.path}}</strong>
+					<li>{{i.path}}
 					({{i.size|filtered_filesizeformat}})</li>
                                   {% endfor %}
 				</ul>
@@ -114,7 +114,7 @@
 <!-- build summary -->
 <div class="row-fluid span10 pull-right">
 <h2>Build summary</h2>
-    <div class="well span4" style="margin-left:0px; background-color:transparent;">
+    <div class="well span4 dashboard-section" style="margin-left:0px;">
         <h4><a href="{%url 'configuration' build.pk%}">Configuration</a></h4>
             <dl>
         <dt>Machine</dt><dd>{{build.machine}}</dd>
@@ -122,7 +122,7 @@
         <dt>Layers</dt>{% for i in build.layer_version_build.all|dictsort:"layer.name" %}<dd>{{i.layer.name}}</dd>{%endfor%}
             </dl>
     </div>
-    <div class="well span4" style="background-color:transparent;">
+    <div class="well span4 dashboard-section">
         <h4><a href="{%url 'tasks' build.pk%}">Tasks</a></h4>
             <dl>
         <dt>Total number of tasks</dt><dd><a href="{% url 'tasks' build.pk %}">{{build.task_build.all.count}}</a></dd>
@@ -151,7 +151,7 @@
         </dd>
             </dl>
     </div>
-    <div class="well span4" style="background-color:transparent;">
+    <div class="well span4 dashboard-section">
         <h4><a href="{% url 'recipes' build.pk %}">Recipes</a> & <a href="{% url 'packages' build.pk %}">Packages</a></h4>
             <dl>
         <dt>Recipes built</dt><dd><a href="{% url 'recipes' build.pk %}">{{recipecount}}</a></dd>
Signature · 1 line
1.9.1
#15 lore raw

PATCH 13/14 toaster: correct package count

In reply to Alex DAMIAN

From: Farrell Wymore <[email protected]>

The package count was incorrect because it was counting anonymous packages. the full path of the image files was shortened to just the filename.

[YOCTO 6087]
[YOCTO 6091]

---
 .../toastergui/templates/builddashboard.html       |  2 +-
 lib/toaster/toastergui/views.py                    | 73 ++++++++++++++--------
 2 files changed, 47 insertions(+), 28 deletions(-)
lib/toaster/toastergui/templates/builddashboard.html +1 -1
index 891d860..fa4b194 100644
@@ -155,7 +155,7 @@
         <h4><a href="{% url 'recipes' build.pk %}">Recipes</a> & <a href="{% url 'packages' build.pk %}">Packages</a></h4>
             <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 %}">{{build.package_set.all.count}}</a></dd>
+        <dt>Packages built</dt><dd><a href="{% url 'packages' build.pk %}">{{packagecount}}</a></dd>
             </dl>
     </div>
 </div>
lib/toaster/toastergui/views.py +46 -27

97 lines not on this page · raw message

Signature · 1 line
1.9.1
#16 lore raw

PATCH 14/14 toaster: added covered task list

In reply to Alex DAMIAN

From: Farrell Wymore <[email protected]>

if a task has a 'covered' indication, the list of tasks that covered the task are computed and displayed. amended to add tooltip.

[YOCTO #5925]

---
 lib/toaster/toastergui/templates/task.html | 11 ++++-
 lib/toaster/toastergui/views.py            | 64 ++++++++++++++++++++----------
 2 files changed, 52 insertions(+), 23 deletions(-)
lib/toaster/toastergui/templates/task.html +10 -1
index c1504b6..66a6695 100644
@@ -109,7 +109,16 @@
             </dt>
             <dd>
                 <ul>
-                    <li><p class="alert-info">TODO:Covering tasks will be displayed here</p></li>
+                  {% for t in covered_by %}
+                    <li>
+                      <a href="{%url 'task' t.build.pk t.pk%}"
+                         class="task-info"
+                        title="{{t.get_executed_display}} | {{t.get_outcome_display}}">
+                        {{t.recipe.name}}_{{t.recipe.version}}
+                        {{t.task_name}}
+                      </a>
+                    </li>
+                  {% endfor %}
                 </ul>
             </dd>
         </dl>
lib/toaster/toastergui/views.py +42 -22

80 lines not on this page · raw message

Signature · 1 line
1.9.1