summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/ui/toasterui.py
Commit message (Collapse)AuthorAgeFilesLines
* bitbake: cooker/toasterui: Drop SEND_DEPENDS_TREE UI featureRichard Purdie2016-05-141-1/+1
| | | | | | | | | Now the event is sent unconditionally we can drop this feature as its no longer needed. (Bitbake rev: 473deeb0fc6065693e1fcfcbb8b79753103db537) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: bitbake: Update logger.warn() -> logger.warning()Richard Purdie2016-05-111-3/+3
| | | | | | | | | | python deprecated logger.warn() in favour of logger.warning(). This is only used in bitbake code so we may as well just translate everything to avoid warnings under python 3. Its safe for python 2.7. (Bitbake rev: 676a5f592e8507e81b8f748d58acfea7572f8796) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: shutdown on BuildCompleted eventEd Bartosh2016-04-061-5/+8
| | | | | | | | | | | | | | | | | | | | | toasterui exits event loop on one of the following events: CommandCompleted, CommandFailed or CommandExit. Unfortunately none of them come from bitbake when build fails. This is normai if toasterui runs in observer mode. However, if it's in build mode this causes toasterui to stuck in the infinite loop waiting for new events. The only event we can rely on is BuildCompleted as it always comes from bitbake unlike 3 above mentioned events. Modified the code to always shutdown toasterui in build mode on BuildCompleted event. (Bitbake rev: 9cd60f98b13cf7b1c518851a51e1cbaa596d8f81) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: fix brbe reportingEd Bartosh2016-04-061-3/+3
| | | | | | | | | | | | | | | | | buildinfohelper.brbe is lost when buildinfohelper is closed. This causes incorrect report of brbe when build is done. Saved brbe attribute before closing buildinfohelper and used it to report correct brbe. Got rid of useless and confusing 'ToasterUI build done 1' log message. (Bitbake rev: 5d7cce0d0ed70f6b3ebd6cbad300d86964a13398) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: add brbe parameter to buildinfohelperEd Bartosh2016-04-061-1/+2
| | | | | | | | | | | | | | | | | | | In current toaster code BRBE(build request:build environment) value is passed from toaster to buildinfohelper through the 'SetBRBE' event. Passing it through environment variable is easier as it doesn't involve rpc communication between toaster and bitbake server. It also eliminates the need in running bitbake observer process. Added parameter 'brbe' to BuildInfoHelper.__init__ Used environment variable TOASTER_BRBE to set brbe for buildinfohelper object. (Bitbake rev: a0c8e2b309055e5927a8ff729d292ccaa69d0575) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: remove ParseStarted from the event listEd Bartosh2016-03-231-1/+0
| | | | | | | | | | | | | | bb.event.ParseStarted event is not processed by toasterui, but present in event list. This causes the following error: WARNING: Unknown event: <bb.event.ParseStarted object at ... and non-zero return code: WARNING: Return value is 1 (Bitbake rev: 1cc102f3d83d9467a3a3c422254333796ba95605) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: Remove the excessive exception loggingMichael Wood2016-03-231-7/+0
| | | | | | | | | | | | Remove the very verbose log dump from toasterui. This generates several megabytes of not that useful debug information and actually hinders finding the original exception. (Bitbake rev: a21dc134bdce2c9eb5e47c770094660f0c45c398) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: fix warning 'Unknown event'Ed Bartosh2016-03-071-0/+1
| | | | | | | | | | | Continue after processing BuildStarted event to fix WARNING: Unknown event: <bb.event.BuildStarted object at 0x2554150> (Bitbake rev: 12f1fb8c9b70fea0c9145f881bcceb8af32df6af) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: exit on final eventsEd Bartosh2016-03-071-1/+4
| | | | | | | | | | | | | | | Toasterui exits only if bitbake observer shuts down. In build mode it should exit when build is done. Made toasterui exit on bb.command.CommandCompleted, bb.command.CommandFailed and bb.command.CommandExit events when it's running in build mode. (Bitbake rev: b11f9d6d3c2eb615335901e1dcea699daf3afb4c) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: make toasterui to work in build modeEd Bartosh2016-03-071-2/+17
| | | | | | | | | | | | | | | Currently toasterui works only in observer mode. This is artificial limitation which was made to support current toaster design. As we decided to stop using bitbake server we'll need to run toasterui also in build mode. [YOCTO #7880] (Bitbake rev: d4b5796899c3ca5c7becd7322291afd8afb35a31) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: check if setEventMask succeededEd Bartosh2016-03-071-2/+4
| | | | | | | | | | | | | | | Currently toasterui ignores return value of setEventMask command, which created confusing difference between set of events set by this command and the real set used in the code. Checked if setEventMask succeeded. Print error message and exit if it's not. (Bitbake rev: 6e3f13ffb47102b5df2da91fbc3f5da3179245b2) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: update list of eventsEd Bartosh2016-03-071-15/+12
| | | | | | | | | | | Removed events not used in the code from the list. Added events that are used in the code. (Bitbake rev: 16b14ec16049cc2040a60ad5fc95f6e19dda91a6) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: reformat list of eventsEd Bartosh2016-03-071-9/+27
| | | | | | | | | | | Reformatted and reordered list of events to make changes easily and see them clearly in the diffs. (Bitbake rev: 42a2d1115f2b23dc063a3172285ca3be73cf70bb) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: log OSErrorException metadata eventsElliot Smith2016-01-181-0/+2
| | | | | | | | | | | | | | | | OSErrors occurring in toaster.bbclass are converted to OSErrorException metadata events. They were then being swallowed as unprocessed events by toasterui, which made them difficult to spot. Explicitly catch OSErrorException events and log them so they are easier to spot and debug. (Bitbake rev: 69f2b2bc373ce114609600b59a6b6ccef20771c9) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: listen for bb.event.MetadataEventElliot Smith2016-01-181-1/+2
| | | | | | | | | | | | | | | | | | The event mask for toasterui doesn't include MetadataEvents. This means that we're missing the ArtifactFileSize event (among others), which is the one we use to populate the SDK artifact table. Add that event type to the toasterui event mask so we can record SDK artifacts as they are created. [YOCTO #7603] (Bitbake rev: d0276a831bb8cffd42c8367895633eaa1fa1ed30) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: process SetBRBE eventEd Bartosh2015-12-141-0/+2
| | | | | | | | | | | | | | | | | Currently BRBE is known to toasterui only when build is started. It's passed to it with BuildStarted event. This is too late as if build fails earilier than build starts toasterui can not inform Toaster about the failure. Set BRBE as soon as it's provided by Toaster. This should make toasterui to be able to inform Toaster about early build failures, e.g. failures during recipe parsing. (Bitbake rev: d7819508dac488a64be3caec88db285cda9599ab) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: toasterui Add ParseStarted/ParseProgress events to maskbrian avery2015-12-091-2/+12
| | | | | | | | | | | | | | | | Toaster is not able to see ParseStarted and ParseProgress events for command-line builds. This means it's not possible for Toaster to detect failed builds, if the failure occurs at a point before the BuildStarted event, as the build won't show up at all. Add these events to the event mask, so that Toaster's toasterui can detect and respond to them. (Bitbake rev: 16bfd3e3d145705a2b3a05648ddbcacc7a338dfa) Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: do not terminate bb serverEd Bartosh2015-12-071-9/+5
| | | | | | | | | | | | | | | Toaster needs bb server to be running all the time due to merged analysis and managed modes. Server gets restarted before every build triggered by UI, but it shouldn't be terminated as it will influence command line builds. [YOCTO #8279] (Bitbake rev: e69c87c7842e796ffcd7193ecde22c8f688498f5) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: Create per-build logsElliot Smith2015-10-291-26/+90
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than relying on bug 8411, which is conveniently creating separate log files for each of our builds, create our own log file for each build. The log files are created in the same tmp directories that bitbake users, but are timestamped to the millisecond to avoid name collisions. Each log file is opened on a ParseStarted event (for builds triggered by Toaster) or BuildStarted event (for builds on the command line: Toaster doesn't get the ParseStarted event for command-line builds). The log file is closed on the BuildCompleted event, or if the build fails. Because we start logging on ParseStarted for Toaster builds, we're able to capture the "Build Configuration" section which bitbake writes to output. [YOCTO #8373] (Bitbake rev: 7974203cd8bc66dff1fcc55f8723dedefaf72840) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: bb/ui: Use getSetVariable command for BB_CONSOLELOGRichard Purdie2015-10-291-1/+1
| | | | | | | | | | | | | | | | | | | | Metadata can define BB_CONSOLELOG as containing ${DATETIME} and this can get expanded to a different value each time the variable is read. In the case of BB_CONSOLELOG, this behaviour is not desireable. The values of DATE/TIME are locked down at build time but this is too late for the purposes of ensuring the system can figure out the real value of BB_CONSOLELOG. The best way to do this is to set the variable into the datastore, thereby preserving its value. [YOCTO #8411] (Bitbake rev: 021f2eb55ab5863b57ed1b3f19f1b329bc1ad477) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: Record critical errorsElliot Smith2015-10-161-0/+2
| | | | | | | | | | | | | | | | | | | | Critical errors (where a build failed for reasons of misconfiguration, such as a machine being specified which is not in a project's layers) were being ignored (only log records up to ERROR level were being logged to Toaster's db). This meant that the build would fail but would not correctly report why. Add support for CRITICAL error levels to the LogMessage model, include errors at this level in the errors property for a build, and show errors at this level in the build dashboard. [YOCTO #8320] (Bitbake rev: b6eacbca9cacb607de864ab7d093deb296da8226) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: use meaningful logging levelsEd Bartosh2015-10-111-4/+4
| | | | | | | | | | Changed logging levels to more appropriate ones. (Bitbake rev: 27d0360d13af0c698bf3a224b3f0d415f17bb678) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: ignore ReachableStamps eventEd Bartosh2015-10-111-1/+2
| | | | | | | | | | | | Added ReachableStamps event to the list of known events to ignore. This should stop toaster throwing error message: ERROR: Unknown event: <bb.event.ReachableStamps> (Bitbake rev: cd4137e13af6964858640b78aa7fe6f1612be251) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: Read correct cooker log path from toasteruiElliot Smith2015-09-181-1/+1
| | | | | | | | | | | | | | | | | | | The BB_CONSOLELOG variable changes by the time we read it in BuildInfoHelper. This means that the log file location we are using is incorrect, so the links to the cooker logs don't work. Instead, read it at the point when the BuildStarted event occurs in toasterui. The BB_CONSOLELOG variable has the correct value here, so pass that to BuildInfoHelper. [YOCTO #8209] (Bitbake rev: 20609eebee0d2318806cf81913e7ce6dc1005507) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster logger: fix pylint issuesAlexandru DAMIAN2015-08-191-30/+27
| | | | | | | | | | | | | | | | | | | | This patch fixes pylint issues in the toaster build data logger, toasterui. The following types of warnings are touched here: * fixing imports * unused variables are set to _ * logger calls now use lazy evaluation instead of formatting the string * correct whitespace identation * removes unneeded "pass" statements, and extra parantheses * disable specific pylint warnings when decideing to override them (Bitbake rev: 947d47f15048baa967f88e03d80014e88ce152aa) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: fix pylint errorsAlexandru Damian2015-08-191-2/+3
| | | | | | | | | | | | | | | | | | | | Prompted by issues discovered during running pylint on the toaster sources, this patch fixes: * missing import in toaster ui * improper call of function in toaster ui (logger.debug) * improper function definitions in bbcontroller * invalid references to objects in bldcontrol.models * proper initialization of object fields in ToasterTables Also inhibiting specific pylint errors in files where the problems are mis-identified. (Bitbake rev: 1c71955c416fb68455f7f70669aba4202c411807) Signed-off-by: Alexandru Damian <alexandru.damian@intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: bitbake: toaster: Wait for toaster gui to comeEd Bartosh2015-08-011-0/+1
| | | | | | | | | | | | | | | Set logging level for the Toaster logger to get messages to toaster_ui.log Reverted previous workaround. [YOCTO: #7965] (Bitbake rev: f1d8e0ff7233f17cff3a56db10d2443b392b407d) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: Fix build execution regressionMichael Wood2015-07-021-0/+1
| | | | | | | | | | | | Make sure the error value is initialised and update the string match that we have to identify bitbake's current startup status. Patch contribution from Eduard Bartosh (Bitbake rev: 915ba08a8a3013e9787e564f2ffd8698c948f433) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: refactor build modelAlexandru DAMIAN2015-06-261-0/+3
| | | | | | | | | | | | | | | | We remove the "timespent", "errors_no" and "warnings_no" fields in favor of computing the needed values at runtime. This prevents inconsistencies in the UI. Also removeing all references to BuildRequests from the interface - all build details now display in the build dashboard. Minor fixes related to data logging. (Bitbake rev: 44f37394ed3e4ca02f940be172fe4395b0ee0f7d) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: fixes after replacing BuildRequest with BuildAlexandru DAMIAN2015-06-261-14/+10
| | | | | | | | | | | This is a set of fixes that repair the interface after we switched from displaying BuildRequest data to Build data in the formerly "managed" mode. (Bitbake rev: 57f790b0c56297af8c83d5def8461bd5d61fe4af) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: close build on BuildCompleted eventAlexandru DAMIAN2015-05-081-16/+18
| | | | | | | | | | | 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. (Bitbake rev: af63abe88327fd5c1b3d7c00a84d9e408ef23285) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: proper exit code on toaster errorsAlexandru DAMIAN2015-05-081-5/+6
| | | | | | | | | | | | | | | | This patch modifies the toasterui to properly return the exit code based on the errors found in the toaster itself. The upload event file API call will not delete event logs for which toasterui showed an error. This will facilitate debugging. Minor enhancement in the buildinfohelper to reduce the number of lookups on unknown layer objects (prevented testing of the patch). (Bitbake rev: 1ddd6a9e4280a4adf971132ff1fe7ec9b3252905) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: enable sanity checkerAlexandru DAMIAN2015-03-251-1/+1
| | | | | | | | | | | 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. (Bitbake rev: 260dd77fa771ae3b777134f4178d344e96b6f3d6) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: improve info in the toaster_ui.logAlexandru DAMIAN2015-03-211-0/+8
| | | | | | | | | | We improve logging and signalling of errors in the toaster_ui.log to facilitate debugging on remote systems. (Bitbake rev: 3cd248f99b90367bd41aab81e255fc1912434890) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: bitbake cooker log saving and downloadingAlexandru DAMIAN2015-02-201-2/+27
| | | | | | | | | | | | | | | | | | | | | This patch brings in cooker log saving and proper download links. * toasterui will now write the cooker log file if running in managed mode * the BuildRequest has a new state, REQ_ARCHIVE, indicating that the build is completed, and the artifacts are ready to be grabbed * the runbuild test execution commands will gather needed artifacts, and save them to a storage directory selected during Toaster setup. * the build dashboard, project builds and all builds pages have permanent links for the cooker log [YOCTO #7220] [YOCTO #7206] (Bitbake rev: fad80e36c9da663b000cdf2cb3c75440c6431d84) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: add option to write offline event log fileAlexandru DAMIAN2014-12-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds a "-w/--write-log" option to bitbake that writes an event log file for the current build. The name of the file is passed as a parameter to the "-w" argument. If the parameter is the empty string '', the file name is generated in the form bitbake_eventlog_DATE.json, where DATE is the current date and time, with second precision. The "-w" option can also be supplied as the BBEVENTLOG environment variable. We add a script, toater-eventreplay, that reads an event log file and loads the data into a Toaster database, creating a build entry. We modify the toasterui to fix minor issues with reading events from an event log file. Performance impact is undetectable under no-task executed builds. (Bitbake rev: 1befb4a783bb7b7b387d4b5ee08830d9516f1ac2) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: add extra debug and development infosAlexandru DAMIAN2014-12-181-9/+10
| | | | | | | | | | | | | | | | | | | | | | We update and add logs throughout the code in order to help with development. The extra logging is turned off by default, but it can be enabled by using environment variables. All logging happens through the Python logging facilities. The toaster UI will save a log of all incoming events if the TOASTER_EVENTLOG variable is set. If TOASTER_SQLDEBUG is set all DB queries will be logged. If TOASTER_DEVEL is set and the django-fresh module is available, the module is enabled to allow auto-reload of pages when the source is changed. (Bitbake rev: 10c27450601b4d24bbb273bd0e053498807d1060) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: add build artifacts table and other improvementsAlexandru DAMIAN2014-12-181-0/+4
| | | | | | | | | | | | | | | | | | We add a BuildArtifacts class to store data about files discovered during the build process and not stored anywhere else. Small cosmetic changes in the toasterui. Add model methods to return file path display data relative to the build environment instead of absolute file paths. [YOCTO #6834] (Bitbake rev: bbe24d912869312d561be199b2c029b0c898e049) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: Compatibility patch for daisy and dizzyAlexandru DAMIAN2014-11-281-2/+1
| | | | | | | | | | | | | | This patch brings in changes that allow a toasterUI coming in from 'master' branch to record data from a 'daisy' or 'dizzy' bitbake server. This is needed to allow Toaster to record builds running on older branch releases. (Bitbake rev: 8d75e28e0688a6520311afce36543175f36910b3) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: display Toaster exceptions and other fixesAlexandru DAMIAN2014-11-281-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | Changing ToasterUI to log toaster exceptions on a different level than build errors. Updating the build dashboard to show Toaster exceptions. We add extra logging to console for exceptions. Fixed a problem where packages database entries were created instead of being looked up in the database, conficting with entries created to satisfy dependency information. Toaster now checks for invalid states at startup and performs needed cleanups. Removed loading reference to jquery-ui.min.css as we do not have this file. (Bitbake rev: 2378812bc24d433125fb940f110154f0ce638448) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: performance improvementsAlexandru DAMIAN2014-11-121-1/+9
| | | | | | | | | | | | | | | | | | | Improve the performance of data logging in toasterui. We modify the data queries used to: * cache searching in memory * insert in bulk (i.e. multiple values per insert, where possible) On development test rig (networked mysql), on no-op build, time for data recording is reduced from 4:10 to 1:30 (minutes). We also improve the logging, so it is easier to detect toasterui errors. (Bitbake rev: d42784432f927f58730caf80546c66772e0fec89) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: improvements in data readingAlexandru DAMIAN2014-11-061-2/+4
| | | | | | | | | | | | | | | | | | | | | We add improvements in data reading, following issues discovered in testing. - elapsed_time is now read from buildstats - we add safeguards to not fail logging if the build was triggered with a toaster_brbe configuration, but it's running in 1.6 mode - added log markups for build finish to let other programs known when the work is done. [YOCTO #6833] [YOCTO #6685] [YOCTO #6887] (Bitbake rev: 0b225035cefee3d3713a93f9a432e5e4d4e174f1) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: change startup parameter passing to avoid raceAlexandru DAMIAN2014-10-301-2/+3
| | | | | | | | | | | | | | We avoid a race between the setting the TOASTER_BRBE variable and reading the variable in toaster ui by supplying the variable at server startup time through the toaster.conf post-read file. Additional small changes are included, including marking the build request with the environment id of where the build took place. (Bitbake rev: 7c333350418c4140e6c988c5272940f8057d327d) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: refactor log saving and save out-of-build errorsAlexandru DAMIAN2014-08-291-6/+4
| | | | | | | | | | | | | We refactor log saving to go through only one code path. All logs that happened outside the build (i.e. before build starting) now will be logged to either toaster_ui.log if the build command ran in interactive mode, or to the build request errors if the command ran in managed mode. This enables proper display of error logs in project page. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: fix build - project identificationAlexandru DAMIAN2014-07-141-4/+3
| | | | | | | | | | | | | This patches fixes the build - project identification when running under managed mode. The build is assigned to the project from which it was triggered, and to the build request, as to simplify relationships queries in the database. (Bitbake rev: af1d3373706d365f9138caec110fcb20a5966b7b) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: Show in the log that ToasterUi is ready to receive events.Dave Lerner2014-07-141-0/+4
| | | | | | | | | | | | | | | | | | | | Issue: TA53702 It was observed that a sequence in a script such as bitbake --server-only .. bitbake --observe-only .. bitbake <some target> could generate events from the server to the observer before the observer was ready to read the events, and the early events of builds were consistently dropped. Adding a "ready" note in the log allows the script to scan for that message before proceeding to building a target. (Bitbake rev: 9949948f92bbe2717a05a380d3df63a332d39c9a) Signed-off-by: Dave Lerner <dave.lerner@windriver.com> Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: build control functionalityAlexandru DAMIAN2014-06-131-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We add the build control functionality to toaster. * The bldcontrol application gains bbcontroller classes that know how to manage a localhost build environment. * The toaster UI now detects it is running under build environment controller, and update the build controller database and will shut down the bitbake server once the build is complete. * The toaster script can now run in standalone mode, launching the build controller and the web interface instead of just monitoring the build, as in the interactive mode. * A fixture with the default build controller entry for localhost is provided. [YOCTO #5490] [YOCTO #5491] [YOCTO #5492] [YOCTO #5493] [YOCTO #5494] [YOCTO #5537] (Bitbake rev: 10988bd77c8c7cefad3b88744bc5d8a7e3c1f4cf) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: update toaster to run in managed modeAlexandru DAMIAN2014-06-061-4/+12
| | | | | | | | | | | | | | We disable bitbake self start to prevent race condition. ToasterUI will shutdown the server when the build is done if running in managed mode. We fix usage of kill server flag in the bitbake binary. (Bitbake rev: 30159dbda3a40fa596302f91c705cb5f148c97a9) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toasterui: save warnings from non-build contextAlexandru DAMIAN2014-04-051-1/+2
| | | | | | | | | | | | | | | | 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] (Bitbake rev: fc7a74e7961775b5d7ff25298abed10138d24dc9) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bitbake: toaster: clean exit on bb server shutdownAlexandru DAMIAN2014-03-251-2/+5
| | | | | | | | | | | | This patch adds the capability to have the Toaster UI detect when the Bitbake server exited and cleanly trigger a clean shutdown of the system through the toaster starting script. (Bitbake rev: a9cfa3eacfc99550e1ad3f8bb61b2a0bc9b44332) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>