Use the project page to select the machine rather than setting it and
then redirecting to the project page. This will also avoid having to have a
special handler in the machines page it's self.
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Michael Wood [Fri, 10 Apr 2015 17:15:03 +0000 (18:15 +0100)]
toaster: Move project context variables to common scope
We have a bunch of context data which are used in multiple pages so it
makes more sense to have this in a single place libtoaster.ctx that's
accessible from each page rather than request it from every page.
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Moving the code to close the build and instantiate a fresh
buildinfohelper object to BuildCompleted event, as the
CommandCompleted/Failed/Exit events come in too early.
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Ed Bartosh [Tue, 28 Apr 2015 11:27:34 +0000 (14:27 +0300)]
bitbake: Handle BBMainException
Some error messages were lost because BBMainException was
inherited from bb.BBHandledException. When bb.BBHandledException
is processed error messages are not printed as they suppose to
be printed before raising this exception.
Stopped to inherit BBMainException from bb.BBHandledException.
Handled BBMainException in bin/bitbake and printed error message
to the stderr.
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Scott Rifenbark [Thu, 16 Apr 2015 20:15:29 +0000 (13:15 -0700)]
bitbake-user-manual: Cleaned up parallelism note and formatted user input
I updated the note in the second chapter that discusses the role for
BB_NUMBER_THREADS. The updates make it a bit clearer.
Also scrubbed the manual for instances of user-supplied values to check
how they are being formatted. I fixed the formatting to use the
<replaceable></replaceable> tags so they are in italics.
Signed-off-by: Scott Rifenbark <scott.m.rifenbark@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Chen Qi [Wed, 11 Mar 2015 03:21:06 +0000 (11:21 +0800)]
bitbake-diffsigs: consider the situation where sigdata and siginfo files having the same hash values
For now, `bitbake-diffsigs -t <recipe> <task>' doesn't work. It always outputs
nothing.
The problem is that bitbake-diffsigs are comparing sigdata and siginfo files
that have the same hash value. This is not what we want. These two files are
actually duplicates considering the purpose of bitbake-diffsigs. So we need
to remove one of them so that bitbake-diffsigs could actually compare the
correct signature files.
Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
David Reyna [Mon, 30 Mar 2015 14:12:01 +0000 (07:12 -0700)]
toaster: recipe path broken in recipe detail page
The recipe paths in managed mode are not processed correctly. They need
any prefix tags removed, and then any build path prefix removed only if
present.
[YOCTO #7523]
Signed-off-by: David Reyna <David.Reyna@windriver.com>
Change the introductory description of Toaster
we provide on first use, to make sure it mentions
all the bits that make up the build system, and
not just BitBake.
Michael Wood [Fri, 27 Mar 2015 15:49:55 +0000 (15:49 +0000)]
toaster: base.js minor jshint fixes
Fixing errors identified by jshint, some missing semicolons and
preference for === operator. Also pass the urldata in libtoaster as an
object rather than constructing a query string.
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Richard Purdie [Tue, 7 Apr 2015 13:14:04 +0000 (14:14 +0100)]
bitbake-layers: ensure non-extended recipe name is preferred
In show-recipes and show-overlayed, we only list one variant of each
recipe where multiple exist, therefore we should show the main one (e.g.
in OpenEmbedded, we now show openssl and not nativesdk-openssl which
would otherwise sort first.)
Fixes [YOCTO #7514].
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Richard Purdie [Mon, 30 Mar 2015 12:29:33 +0000 (13:29 +0100)]
cooker: Ensure bbappend files are processed in a determistic order
self.appendlist is a dict and as such unordered. This can lead to cases
where appends with different names (e.g. x_%.bbappend vs. x_123.bbappend)
can be reordered in application which in turn reorders the variables
that those bbappend files might touch. Reorderd variables changes the sstate
cache signatures causing real world issues.
To avoid this, use a list for the append files instead.
This patch is conservative and just adds a new data structure alongside
the existing one and uses it to resolve the core issue. Later patches
(post release) can handle some of the wider but less problematic ones
(e.g. issues in bitbake-layers flatten).
[YOCTO #7511]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Bug [YOCTO #7334] was incompletly fixed, and the proper fix is
not straightfoward. Consequently we revert the partial fix, as
a incomplete fix is worse than no fix.
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
A recent round of informal user feedback has revealed
that the term 'target' is quite problematic. For
all the users we spoke to the word refers to the
target arch. In Toaster, it refers to the software
you build.
This patch replaces the word 'target' with 'recipe'
across the Toaster interface. This is by no means
self-explanatory, but at least it cannot be confused
with target hardware, and it is also consistent with
the terminology we use in the analysis portion of
the interface.
Signed-off-by: Belen Barros Pena <belen.barros.pena@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Alexandru DAMIAN [Thu, 19 Mar 2015 16:05:03 +0000 (16:05 +0000)]
toasterui: enable sanity checker
Since toasterui acts as the user-facing UI, we need
to run sanity checks in order to let the GUI display proper
warnings and stop the build if something is wrong.
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Dave Lerner [Sat, 14 Mar 2015 14:00:15 +0000 (09:00 -0500)]
toaster: most-build-targets bug fixes
Fixes for the following for the "Most built targets" section of the
project page:
1) limit the number of most built targets to 5,
2) order the list of most built targets by build count,
3) select only those builds that had build status of 'fail', 'success',
or a BuildRequest of 'failed',
4) if there are no layers in the project then (on refresh) all of the
checkboxes in the 'Most built targets' list are disabled.
Note that per agreement with UI designer, the only sort on the most
target list is build count as described in (3) above; secondary sorting
is random.
[YOCTO #7177]
Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
In the layer details page, if the background
information about the layer that shows in the
right hand column is completely empty, remove
it altogether.
If only one release has been set up in Toaster,
any project you create defaults to that release,
and we simply don't show the release selection
menu when creating projects.
However, we were still showing the release information
in the project page, which would leave users wondering
what that release thing is since they never were
exposed to it.
This patch hides the release information in the
project page when only one release has been set
up in Toaster.
Dave Lerner [Wed, 18 Mar 2015 15:52:48 +0000 (10:52 -0500)]
toaster: alert fixes for project release change
When a project release changes, if there are layers included with the
project, then show the release branch name in the layer list. If there
aren't any layers in the project, then suppress the statement on the
changed layers.
[YOCTO # 7168]
Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
The 'Last build' column in the all projects table
was supposed to provide the completion time stamp
of the latest project build. Instead, it is showing
the time stamp of the latest project activity, which
includes:
* when the project was created and
* when the last build started
but not when you make a change to the configuration.
The result is that the column and the sorting are very
misleading. The template is set so that the time stamp
only shows when the project has builds (if 0 builds, no
time stamp is shown). But of course the sorting still
happens according to the value, even if it doesn't
display. The result is that, when you sort by the
'Last build' column, projects with no builds
appear listed between projects with builds, and you
have no idea why.
This patch:
* changes the column label
* its position in the table
* makes sure the time stamp always displays
* and adds help text
to reflect what the data actually means.
It also makes some small changes to other table
headings.
Dave Lerner [Wed, 11 Mar 2015 20:05:08 +0000 (15:05 -0500)]
toaster: layer-relative paths for config files
Change bitbake variables table to show the path to the file in which
the variable was defined using a layer-relative path instead of the
full path to the file.
The layer-relative path is found by matching on the full defining file
path with entries in a list of layer names, sorted in descending order,
and with 'meta' appended as a built-in layer to the end of the list.
Additional filters are used to reduce false matches, although even if
there is a false match, the actual path to the defining file will be
obvious and not misleading.
[YOCTO #7414]
Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
David Reyna [Thu, 12 Mar 2015 23:56:12 +0000 (16:56 -0700)]
toaster: insure IMAGE_INSTALL_append values have a space prefix
When the IMAGE_INSTALL_append value is not empty, it must have a space prefix
in order for the "append" operator to concatenate the values correctly, so we
enforce it in this variable's submit javascript.
[YOCTO #7394]
Signed-off-by: David Reyna <David.Reyna@windriver.com>
Michael Wood [Fri, 13 Mar 2015 15:22:32 +0000 (15:22 +0000)]
toaster: tasks trigger the select related tables before ordering
In two of the cases the data is changed from a QuerySet to a sorted list
so we aren't able to use the QuerySet api at this point, moving it
before the data type is changed fixes this.
[YOCTO #7404]
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Michael Wood [Fri, 13 Mar 2015 14:34:41 +0000 (14:34 +0000)]
toaster: Add cancel build to latest build section
Add this functionality to the common managed_mrb_section
Make sure we are using the correct version of this template in the
projects template and remove now redundant code.
[YOCTO #7351]
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Dave Lerner [Thu, 12 Mar 2015 18:55:27 +0000 (13:55 -0500)]
toaster: leave cancel enabled for release change
When you click the 'change' icon to edit the project release, the
"cancel" button, should always be enabled so that the user can
return to the 'not editable' state at any time.
[YOCTO #7151]
Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
Alexandru DAMIAN [Tue, 10 Mar 2015 18:31:45 +0000 (18:31 +0000)]
toastergui: dirinfo needs path separation
In the dirinfo URLs we use the "/" separator for directory
separation which coincides with the "/" separator in HTTP URIs.
This is not a problem, but we must not have consecutive "/"
characters as the web servers will conflate those - we add
a "_" delimitator to separate the Django managed URL from the
dirpath parameter, while maintaining the unique ID of REST urls.
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
toastergui: improve performance in the all targets page
This patch improves performance in the all targets display
by computing the preffered layer only for displayed targets,
instead of computing for all targets.
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
We modify the project page to provide a consistent view of the
build errors. The display is now similar with the
managed_mrb_section and links point to the buildrequest
detail view.
[YOCTO #7188]
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Paul Eggleton [Mon, 16 Mar 2015 10:35:10 +0000 (10:35 +0000)]
bitbake-layers: use stdout instead of stderr for logging
We use logger.plain() to produce actual output which needs to go to
stdout. We could use more advanced filtering (and probably should in
future) but for the moment let's just fix the regression.
Fixes [YOCTO #7458].
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Richard Purdie [Tue, 10 Mar 2015 10:29:46 +0000 (10:29 +0000)]
cooker/server: Fix up 100% CPU usage at idle
The recent inotify changes are causing a 100% cpu usage issue in the
idle handlers. To avoid this, we update the idle functions to optionally
report a float value which is the delay before the function needs to be
called again. 1 second is fine for the inotify handler, in reality its
more like 0.1s due to the default idle function sleep.
This reverts performance regressions of 1.5 minutes on a kernel build
and ~5-6 minutes on a image from scratch.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
The following workflow (whether accidentally or deliberately) would
previously not result in a checksum error, but would be helpful to do
so:
- Write a recipe with correct checksums
- Fetch the sources for this recipe using bitbake
- Change the checksums
Since the bitbake fetcher writes a done stamp after the initial download
and does not verify the checksums again (even if they are changed in the
recipe afterwards), the change of checksums is silently ignored.
Fix this without the overhead of computing the checksums from scratch on
every do_fetch by storing them in pickled format in the done stamp and
verifying that they still match those in the recipe.
Signed-off-by: Clemens Lang <clemens.lang@bmw-carit.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Dave Lerner [Thu, 5 Mar 2015 23:01:55 +0000 (17:01 -0600)]
toaster: cached outcome download button
When a task is executed successfully without using saved-state cache,
then a button appears allowing the user to download the log file for
that task. This commit allows the user to download the log file for a
task that is completed by unpacking data from the saved-state cache, a
task with outcome 'Cached'. The same button 'Download task log' is
shown, which when pressed downloads the '_setscene' log file for that
task.
[YOCTO #7379]
Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
Michael Wood [Mon, 2 Mar 2015 15:00:49 +0000 (15:00 +0000)]
toaster: Enforce unique layer names
We had some clever functionality to manage duplicate layer names by
using layer versions and new revisions, unfortunately this was too
opaque to the user.
[YOCTO #7337]
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Dave Lerner [Wed, 25 Feb 2015 20:53:22 +0000 (14:53 -0600)]
toaster: commit id format on layers page
On the layers page, when a layer revision is a commit id instead of a
an upstream branch name, then follow the same format for displaying the
commit id as on the recipes page. That format is a button with the
truncated commit SHAID which when pressed expands to the full SHAID.
[YOCTO #7191]
Signed-off-by: Dave Lerner <dave.lerner@windriver.com> Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
toastergui: bring back base URLs for pages that need them
Some URLs, although invalid on their own, are used in JS to
build valid page pointers. Previous patch removed two of these URLs,
breaking the display of several patches.
This patch re-adds these URLs with different names, and returns
400 Bad Request empty pages on them, which is consistent with the
intended usage of these URLs.
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>