Bug 11040

Summary: Order column in Tasks table in toaster UI cant be selected and does not show
Product: [Build System, Metadata & Runtime] Toaster Reporter: Libertad <libertad.gonzalez.de.la.cruz>
Component: toasterAssignee: David Reyna <david.reyna>
Status: RESOLVED FIXED QA Contact: Libertad <libertad.gonzalez.de.la.cruz>
Severity: normal    
Priority: Medium CC: awais_belal, jessica.zhang, stanciux.mihail
Version: 2.3   
Target Milestone: 2.4 M4   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Don't know
Attachments:
Description Flags
Task talbe within the CPU usage view none

Description Libertad 2017-02-09 20:30:49 UTC
Created attachment 3629 [details]
Task talbe within the CPU usage view

STATUS: FAILED
BUILD: 2.3_M2 : 62d7d4130202d8ede16abf9e7d779361ca70847e
ENVIRONMENT: Crops-Toaster container
STEPS TO REPRODUCE: 

 
1. Start Toaster within the Crops container
 
2. In Toaster, create a project, start a build image of core-image-minimal, wait for the build to finish, select the build, and select the "Tasks" link in the left sidebar 
 
3. Click on the Edit Columns button
 
  * Observe that the default columns are:  
   
    "Order, Recipe, Task, Executed, Outcome, Cache attempt" 

 

EXPECTED OUTCOME: 

The default column {ORDER} is not visible in the table and also when displaying the Edit columns button information the Order columns is non selected and cant be selected.
Comment 1 David Reyna 2017-07-27 05:25:48 UTC
The description below mentions the "Tasks" report. That appears fine to me.

The attachment shows that the error is in the "CPU Usage", which I can replicate. I also see it in the "Time" and "Disk I/O" pages.

I expect that there is a simple error in "tables.py" where the column for "Order" is missing.
Comment 2 Awais 2017-07-28 13:21:42 UTC
(In reply to comment #1)
> The description below mentions the "Tasks" report. That appears fine to me.
> 
> The attachment shows that the error is in the "CPU Usage", which I can
> replicate. I also see it in the "Time" and "Disk I/O" pages.
> 
> I expect that there is a simple error in "tables.py" where the column for
> "Order" is missing.

So I had a look at this and it seems this behavior is intended (sort of). The issue as mentioned is due to the implementation in buildtables.py where the tables for Time, CPU usage and Disk IO all set

self.columns[self.toggle_columns['order']]['hidden'] = True

Removing the line shows the Order column as expected but things look a little haywire from aesthetics POV as the table in case of Time would be sorted on the basis of time and not order so the first column (order) shows all sorts of values and doesn't look too good (probably why this wasn't implemented this way in the first place). However, I can submit the change if there are no concerns.
Comment 3 David Reyna 2017-07-31 08:21:13 UTC
> self.columns[self.toggle_columns['order']]['hidden'] = True

Ok, I can accept that as desired behavior.

I would then say that having the "Order" appear in the "Edit Columns" list is confusing, since it there but cannot be seen nor selected.

In other words, I would say that the defect is that "Order" is not also hidden in the "Edit Columns" pull down list.
Comment 4 Awais 2017-08-01 04:18:27 UTC
(In reply to comment #3)
> > self.columns[self.toggle_columns['order']]['hidden'] = True
> 
> Ok, I can accept that as desired behavior.
> 
> I would then say that having the "Order" appear in the "Edit Columns" list
> is confusing, since it there but cannot be seen nor selected.
> 
> In other words, I would say that the defect is that "Order" is not also
> hidden in the "Edit Columns" pull down list.

The handling of "Edit Columns" pull down is generic (table.js/basetable_top.html) and making a change there IMO might cause regression in other places. So, I think just setting the hideable property (so it can be selectable) for "Order" column in tables for Performance would be a better solution here. Comments?
Comment 5 David Reyna 2017-08-09 15:06:28 UTC
Seems fine to me.
Comment 6 David Reyna 2017-09-07 04:40:00 UTC
commit 75e0fb34a19c10c24773b2be259fafd913540c6e