On 15/07/2016 12:51, "[email protected] on behalf of Smith,
Elliot" <[email protected] on behalf of
[email protected]> wrote:

>Because this contains a new JS file (jsrender) which has lines too long
>for
>git send-email, I'm sending it as a pull request.
>
>The branch containing the work described below is:
>
>  poky-contrib, elliot/toaster/9631-recent_builds_states

Hi Elliot,

I've had a look at this branch and have a few comments / questions:

Regarding the build progress feedback:

* One question: does the build say "parsing" while "cloning" is taking
place? I can't be sure, but builds with new layers that need to be cloned
say parsing at 0% for a very long time. Hence the question

* I am seeing some projects where the information in the latest builds
section never moves from "loading". Here is a screenshot:
http://imgur.com/2GOHBHx

* Maybe we can replace the "target unknown" that we show at the beginning
for cli builds with something more hopeful like: "Fetching recipe name". I
don't think we use the word 'target' to refer to build targets anywhere
else.

Regarding the build dashboard changes

* Warnings in the latest builds section look like errors: they have the
wrong colour and icon

* For builds that fail early, warnings are reported (you see the number),
but the content of the warnings is not displayed. For example:
http://imgur.com/14eiK4S

* Finally, it looks like builds with task failures no longer display the
build summary information. Here is an example: http://imgur.com/m0OBKx5

Thanks!

Belén


>
>OVERVIEW
>
>This is a rewrite of the "most recent builds" area.
>
>The most recent builds area (on the all builds and project builds pages)
>now
>shows state for a build as follows:
>
>* Queued (not shown for cli builds): build request created but not
>actioned
>* Parsing recipes: shown as progress bar, using ParseProgress events to
>drive it
>* Tasks starting: shown while bitbake is constructing the runqueue and
>before
>any tasks have been completed
>* Task progress: as tasks are being completed, shown as progress bar
>* Completed or failed state
>
>If a build is cancelled, you will see:
>
>* Cancelling state, while waiting for bitbake to exit (note that this is
>also
>persistent across state reloads, and not just temporarily visible after
>the
>cancel button is clicked)
>
>* Cancelled state
>
>In addition, because this area also impacts and overlaps with fixes for
>other bugs in the build dashboard which I had hanging around, the
>following
>pieces are also on this branch:
>
>* Addition of a BuildInit event to capture failed builds (with bad
>targets)
>earlier. This was required as we need to make a Build object earlier, so
>that
>we have something to attach recipe parse progress to.
>
>* Changes to buildinfohelper so that the Build can be created on
>ParseStarted,
>but later embellished as BuildInit and BuildStarted trigger.
>
>* Hiding the left-hand menu and build summary area for builds which fail
>before
>the BuildStarted event occurs. This entailed adding a started() method to
>Build so that we can tell when BuildStarted has occurred.
>
>* Remove build time links for builds which have no time data (because they
>failed early).
>
>IMPLEMENTATION NOTES
>
>I added a BuildInit event to cooker, which I have tried to do
>(unsuccessfully)
>in previous patches. However, I have amended where this event is fired so
>that
>tasks have been sanitised before they are sent with the event.
>
>I added a new get_state() method to the Build model. This puts the logic
>for
>determining the state of a build in the business logic, instead of partly
>in
>the front end and partly in the UI code.
>
>I also added a /mostrecentbuilds JSON API which the most recent builds
>area
>uses to fetch the build data. This provides a clean separation between
>server
>and client, meaning that the server doesn't have to generate much HTML.
>
>Finally, I moved a lot of templating code to the client so that we don't
>have
>such an unwieldy mix of client-side and server-side templating. The
>templating library I used is jsrender (http://www.jsviews.com/), as this
>integrates simply with jQuery. This makes it much easier to add new state
>transitions to that area of the page (such as the git checkout progress
>we want
>to add later).
>
>RELATED BUGS
>
>https://bugzilla.yoctoproject.org/show_bug.cgi?id=9631 (add state
>transitions
>to most recent builds area)
>
>https://bugzilla.yoctoproject.org/show_bug.cgi?id=8443 (custom dashboard
>for
>builds which fail at the build request stage)
>
>https://bugzilla.yoctoproject.org/show_bug.cgi?id=8440 (better display of
>builds
>which fail at the build request stage)
>
>CHANGES
>
>(I've kept a record of the commits in this pull request for reference, but
>"toaster: move most recent builds templating to client" can't be handled
>by git send-email.)
>
>The following changes since commit
>2a127b1a6cd3df47879bda5e0d7bb123484013cb:
>
>  toaster-tests: add class SeleniumTestCaseBase for browser tests
>(2016-07-15 11:29:29 +0100)
>
>are available in the git repository at:
>
>  git://git.yoctoproject.org/poky-contrib
><http://git.yoctoproject.org/poky-contrib>
>elliot/toaster/9631-recent_builds_states
>  
>http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=elliot/toaster/96
>31-recent_builds_states
>
>Elliot Smith (12):
>  cooker: add BuildInit event
>  toaster: move most recent builds templating to client
>  toaster: show progress of recipe parsing in recent builds area
>  toaster: show "Tasks starting..." until the first task completes
>  toaster: tweak styling and typos in recent builds area
>  toaster: remove links from time field on failed builds
>  toaster: add started property to Build
>  toaster: adjust build dashboard for failed builds
>  toaster-tests: add tests for build time links in the all builds page
>  toaster-tests: add tests for build dashboard menu and summary
>    visibility
>  toaster-tests: add tests for most recent builds state changes
>  toaster-tests: fix erroneous message when test fails
>
> bitbake/lib/bb/cooker.py                           |   4 +
> bitbake/lib/bb/event.py                            |   6 +-
> bitbake/lib/bb/ui/buildinfohelper.py               | 118 ++++---
> bitbake/lib/bb/ui/toasterui.py                     |  31 +-
> .../migrations/0005_reorder_buildrequest_states.py |  19 ++
> bitbake/lib/toaster/bldcontrol/models.py           |  12 +-
> .../0010_recipe_parse_progress_fields.py           |  24 ++
> .../orm/migrations/0011_allow_empty_buildname.py   |  19 ++
> bitbake/lib/toaster/orm/models.py                  |  87 ++++-
> .../toaster/tests/browser/test_all_builds_page.py  |  93 +++++-
> .../tests/browser/test_builddashboard_page.py      |  44 ++-
> .../browser/test_builddashboard_page_artifacts.py  |   7 +-
> .../tests/browser/test_layerdetails_page.py        |   8 +-
> .../browser/test_most_recent_builds_states.py      | 211 ++++++++++++
> bitbake/lib/toaster/toastergui/api.py              | 115 ++++++-
> .../lib/toaster/toastergui/static/css/default.css  |   1 +
> .../toaster/toastergui/static/js/jsrender.min.js   |   4 +
> .../lib/toaster/toastergui/static/js/libtoaster.js |  16 +
> .../lib/toaster/toastergui/static/js/mrbsection.js | 180 ++++++----
> bitbake/lib/toaster/toastergui/tables.py           |   8 +-
> bitbake/lib/toaster/toastergui/templates/base.html |   5 +
> .../toastergui/templates/basebuildpage.html        | 174 +++++-----
> .../toastergui/templates/builddashboard.html       | 188 ++++++-----
> .../toastergui/templates/buildrequestdetails.html  |  64 ----
> .../toaster/toastergui/templates/mrb_section.html  | 371
>+++++++++++++--------
> .../templates/projectbuilds-toastertable.html      |   2 +-
> .../toaster/toastergui/templatetags/projecttags.py |   8 -
> bitbake/lib/toaster/toastergui/urls.py             |   3 +
> 28 files changed, 1277 insertions(+), 545 deletions(-)
> create mode 100644
>bitbake/lib/toaster/bldcontrol/migrations/0005_reorder_buildrequest_states
>.py
> create mode 100644
>bitbake/lib/toaster/orm/migrations/0010_recipe_parse_progress_fields.py
> create mode 100644
>bitbake/lib/toaster/orm/migrations/0011_allow_empty_buildname.py
> create mode 100644
>bitbake/lib/toaster/tests/browser/test_most_recent_builds_states.py
> create mode 100644
>bitbake/lib/toaster/toastergui/static/js/jsrender.min.js
> delete mode 100644
>bitbake/lib/toaster/toastergui/templates/buildrequestdetails.html
>
>
>-- 
>Elliot Smith
>Software Engineer
>Intel Open Source Technology Centre
>
>
>

-- 
_______________________________________________
toaster mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/toaster

Reply via email to