summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/orm/migrations
AgeCommit message (Collapse)Author
2018-08-20bitbake: Toaster: Implement the project-specific feature and releated ↵David Reyna
enhancements and defects. Here is the primary driving enhancement: * Bug 12785 - Support Project Specific configuration for external tools (e.g. ISS, Eclipse) - Isolated project-specific configuration page (full Toaster context hidden) - Support for new project, reconfigure existing project, and import existing command line project - Ability to define variables (e.g. image recipe) and pass them back to external GUI - Ability to execute the cloning phase, so that external GUI receive a buildable project - Ability to call back to the external GUI when updates are completed and ready - Compatibility of above projects with the normal full Toaster interface - Ability to pass to a 'complete' or 'cancel' web page so that the external GUI can immediately stop that Toaster instance, and not leave dangling servers nor edit sessions open Here are the supporting enhancements, where at least the back end is implemented: * Bug 12821 - Make Toaster conf changes compatible with command line usage * Bug 12822 - Support importing user changes to conf files into Toaster * Bug 12823 - Support importing user build directories into Toaster * Bug 12824 - Scan imported layers for content so that they are immediately available * Bug 12825 - show layer clone item in progress bar Here are defects fixed: * Bug 12817 - builddelete.py requires explicit 'add_arguments' * Bug 12818 - Remove orphaned imported layers when project is deleted * Bug 12826 - fix imported layer management * Bug 12819 - build using selected bitbake env, not Toaster's env * Bug 12820 - Toaster randomizes the layer order in toaster_bblayers.conf [YOCTO #12785] (Bitbake rev: 985d6cec290bdd80998a63483561a73c75d82d65) Signed-off-by: David Reyna <David.Reyna@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-07-21bitbake: toaster: set clone progress default to offDavid Reyna
Set the clone progress to be off by default for the benefit of command line projects and 'Local Yocto' builds. For Toaster managed projects that do use the clone feature the clone progress status is already explicitly set by the existing code and thus displayed. [YOCTO #11744] (Bitbake rev: d25a3088150b2a277242027c12becdeb88c45517) Signed-off-by: David Reyna <David.Reyna@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-28bitbake: toaster: Add distro selection supportDavid Reyna
Add the ability to select a distro in the project page, based on values from the Layer Index. Add a distro selection page with the add layer feature, based on the add machine page. [YOCTO #10632] (Bitbake rev: a156a4eff67cdc3943494f5be72b96e3db656250) Signed-off-by: David Reyna <David.Reyna@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-28bitbake: toaster: git clone progress barDavid Reyna
If a project has a lot of additional layers, the build may appear to hang while those layers are checked out. This patch adds a clone progress bar that is visible before the parsing progress appears. [YOCTO #9916] (Bitbake rev: 0c94d947b74c4dee23d7b9d255facd3cf839ccbe) Signed-off-by: David Reyna <David.Reyna@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-11bitbake: toaster: add local_source_dir field to modelSujith H
Add a new field local_source_dir to model. This will clearly differentiate us from the vcs_url which is for git path. Adding migration file 0010_layer_local_source_dir_path.py along with this patch. [YOCO #9911] (Bitbake rev: 83763d89f9d0bc535e930a2094ba8201675d40be) Signed-off-by: Sujith H <sujith.h@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-11bitbake: toaster: show progress of recipe parsing in recent builds areaElliot Smith
Modify buildinfohelper and toasterui so that they record the recipe parse progress (from ParseProgress events in bitbake) on the Build object. Note that because the Build object is now created at the point when ParseStarted occurs, it is necessary to set the build name to the empty string initially (hence the migration). The build name can be set when the build properly starts, i.e. at the BuildStarted event. Then use this additional data to determine whether a Build is in a "Parsing" state, and report this in the JSON API. This enables the most recent builds area to show the recipe parse progress. Add additional logic to update the progress bar if the progress for a build object changes. [YOCTO #9631] (Bitbake rev: f33d51d46d70e73e04e325807c1bc4eb68462f7b) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-01bitbake: lib/toaster: Fix missing new files from previous commitsRichard Purdie
(Bitbake rev: f77e6f21a2cc57a3fcb5970437e55cfae39849a3) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-07-19bitbake: toaster: add package manifest path to Target objectsElliot Smith
Store the path to the *.rootfs.manifest file for targets which generate images. A link to the package manifest is displayed in the build dashboard for targets which produce image files. Like the license manifest path, if a target would have produced the package manifest (but didn't, because it already existed), that path is copied from the target which did produce the package manifest. (Bitbake rev: 79b8e349a0da2ea6b97ad82daa5837e6dfffe0af) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: bavery <brian.avery@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-07-19bitbake: toaster: improve scan for SDK artifactsElliot Smith
SDK artifacts were previously picked up by toaster.bbclass and notified to buildinfohelper (via toasterui). The artifacts were then added to the Build object, so that it wasn't clear which artifact went with which target; we were also unable to attach SDK artifacts to a Build if they had already been attached to a previous build. Now, toaster.bbclass just notifies the TOOLCHAIN_OUTPUTNAME when a populate_sdk* target completes. The scan is moved to buildinfohelper, where we search the SDK deploy directory for files matching TOOLCHAIN_OUTPUTNAME and attach them to targets (not builds). If an SDK file is not produced by a target, we now look for a similar, previously-run target which did produce artifacts. If there is one, we clone the SDK artifacts from that target onto the current one. This all means that we can show SDK artifacts by target, and should always get artifacts associated with a target, regardless of whether it really build them. This requires an additional model, TargetSDKFile, which tracks the size and path of SDK artifact files with respect to Target objects. [YOCTO #8556] (Bitbake rev: 5e650c611605507e1e0d1588cd5eb6535c2d34fc) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: bavery <brian.avery@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-07-19bitbake: toaster: attach kernel artifacts to targetsElliot Smith
The bzImage and modules files were previously attached to a build, rather than to the target which produced them. This meant it was not possible to determine which kernel artifact produced by a build came from which target; which in turn made it difficult to associate existing kernel artifact with targets when those targets didn't produce artifacts (e.g. if the same machine + target combination was built again and didn't produce a bzImage or modules file because those files already existed). By associating kernel artifacts with the target (via a new TargetArtifactFile model), we make it possible to find all the artifacts for a given machine + target combination. Then, in cases where a build is completed but its targets don't produce any artifacts, we can find a previous Target object with the same machine + target and copy its artifacts to the targets for a just-completed build. Note that this doesn't cover SDK artifacts yet, which are still retrieved in toaster.bbclass and show up as "Other artifacts", lumped together for the whole build rather than by target. [YOCTO #8556] (Bitbake rev: 9b151416e428c2565a27d89116439f9a8d578e3d) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: bavery <brian.avery@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-15bitbake: toaster: fix migrationsEd Bartosh
(Bitbake rev: bfb44886c3bec8320e4f845c9ff24ae2a795aa9f) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-04-06bitbake: toaster: models Add cancelled state to build outcomeSujith H
A new state CANCELLED is introduced to, distinguish the state of build. [YOCTO #6787] (Bitbake rev: 404f406fecae879703bcfe96f3b65086b115fa8a) Signed-off-by: Sujith H <sujith.h@gmail.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-09bitbake: toaster: rework task buildstats storage and displayElliot Smith
The data available from buildstats is now more fine grained than previously, so take advantage of that to enrich the data we save against tasks: * Store the CPU usage for user and system separately, and display them separately. * Disk IO is now measured in bytes, not ms. Also store the read/write bytes separately. * Store started and ended times, as well as elapsed_time. This will enable future features such as showing which tasks were running at a particular point in the build. There was also a problem with how we were looking up the Task object, which meant that the buildstats were being added to new tasks which weren't correctly associated with the build. Fix how we look up the Task (only looking for tasks which match the build, and the task and recipe names in the build stats data) so the build stats are associated with the correct task. [YOCTO #8842] (Bitbake rev: efa6f915566b979bdbad233ae195b413cef1b8da) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-19bitbake: toaster: orm migrations Sort out migrations messMichael Wood
We messed up the migrations by squashing some of the image customisation model definitions into the initial migration which has meant some irreversible operations on mysql took place. This deletes, re-orders and fixes the migrations. If your schema is up to date you may want to use ./manage migrate with --fake or --fake-initial to avoid re-applying migrations. [YOCTO #9116] (Bitbake rev: 19bd63fc3a28dcbd0f531a5b06a037da34568bac) Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-10bitbake: toaster: orm Add last_updated field to CustomImageRecipeMichael Wood
Field to keep track of when the package list for the CustomImageRecipe was last updated from a build. (Bitbake rev: 4bd4e49f13a7625997a43f3b2e67ed42c3c8e08b) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-10bitbake: toaster: update customimagerecipe migrationElliot Smith
When applying migrations, Django shows this warning: "Your models have changes that are not yet reflected in a migration, and so won't be applied." This is because the customimagerecipe model has changed, but those changes are not covered by a migration. Add the missing migration to clear this warning. (Bitbake rev: df8185fcbd84061976d91b03b2a9268b319a6184) 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>
2016-02-10bitbake: toaster: add merge migration to resolve conflictElliot Smith
Django detects a conflict between a migration added to support image customisation and another migration which supports PROVIDES. Add a merge migration to resolve the conflict (as suggested by Django). (Bitbake rev: a26bfd9d2490dc0fd90bf6d1690e63ac26001559) 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>
2016-02-10bitbake: toaster: orm: Add db migration for new CustomImagePackage tableMichael Wood
(Bitbake rev: c7da71fe8509439656f482c16ed081cf442f4030) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-10bitbake: toaster: orm: Add db migration for new CustomImageRecipe ↵Michael Wood
inheritance change (Bitbake rev: 2831d74201abba68c301d85ee583d706a51d5a5f) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-11bitbake: toaster: add Provider modelEd Bartosh
Added new model Provider and a foreign key 'via' to link Recipe_Dependency to it. [YOCTO #6169] (Bitbake rev: e45fff6314741d46e2549b2f72ed380cbbb95593) 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>
2015-12-14bitbake: toaster: Remove South migrationsEd Bartosh
South has been deprecated in favour of Django's own migration framework, so remove the old South migrations and replace them with Django ones. [YOCTO #8364] (Bitbake rev: 427d8bc02d1aa00a19057602d592d58334514804) Signed-off-by: Elliot Smith <elliot.smith@intel.com> 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>
2015-10-27bitbake: toaster: orm Fix restrictive LogMessage message lengthMichael Wood
Log messages can be quite long so use a TextField rather than a char field with max length of 240. mySQL is especially picky about field lengths and will cause an exception if the log is too long. [YOCTO #8475] (Bitbake rev: 349119f44cdad240dda7f4db45992e2539e1416f) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-09-29bitbake: toaster: Add CustomImageRecipe modelMichael Wood
This model lists custom image recipes for the project. It is populated when new custom image is created. It holds reference to the base recipe and list of packages included into custom image. For CustomImageRecipes the packages will be copied in and therefore not associated with a build so Remove the requirement for the package to have a Build. co-author: Ed Bartosh <ed.bartosh@linux.intel.com> (Bitbake rev: 33cbf4cd3b4ca47c4901501f5f1eafdfdfdae023) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-09-03bitbake: toaster: Improve how default project is identified and fetchedElliot Smith
Command line builds are associated with a "default project" (as we currently require a build to have a project). This acts as a container for builds initiated outside Toaster. Currently, this project is marked as the default by its ID being 0. However, this doesn't work with MySQL, as MySQL won't allow 0 in a foreign key which references an autoincrement field. Instead, use an is_default field to track the default Project for builds initiated outside Toaster. Add a method to fetch this default project, rather than fetching a project with a magic ID. Add this default project in a migration, rather than as a side effect of a get_or_create() style method. Also ensure that builds always have a project explicitly assigned to avoid any magic with a build's project foreign key defaulting to 0 (as it no longer does). [YOCTO #7932] (Bitbake rev: 71b709a1bbc26d89d61873763b467d21e625b274) 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>
2015-09-03bitbake: toaster: Make 0021 migration compatible with MySQLElliot Smith
Two issues prevent this migration from working correctly with a MySQL back-end: 1. MySQL won't allow a default value to be set for an AutoField, which is what the migration tries to do for project_id ("ValueError: The database backend does not accept 0 as a value for AutoField.") 2. When migrations are applied to a MySQL back-end, Django (via South) attempts a dry run of the migration first: it applies the forward migration then rolls it back. However, this migration raises an exception on roll back, which causes the whole series of migrations to fail. This commit fixes both issues. [YOCTO #7932] (Bitbake rev: 12f6278d56d7dec57308adc17411802f15d395d7) 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>
2015-08-01bitbake: bitbake: toaster: Add is_image field to the Recipe modelEd Bartosh
Added new field is_image to the Recipe model. Made sure is_image is populated when layer sources are imported. Made sure the change doesn't break loading old style layer sources. Tested by loading data from layers.pythonanywhere.com and from layers.openembedded.org. [YOCTO: #7571] (Bitbake rev: 3ac0ba73790b8f68567daa2de313c78053411fbb) 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>
2015-06-26bitbake: toaster: refactor build modelAlexandru DAMIAN
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>
2015-06-26bitbake: toaster: fixes after replacing BuildRequest with BuildAlexandru DAMIAN
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>
2015-05-29bitbake: toaster logger: assign projects to all buildsAlexandru DAMIAN
Bitbake logger now sets a default project if the TOASTER_BRBE or TOASTER_PROJECT Bitbake variables are not set. This a necessary step in getting all builds under a project, as to unify the MANAGED and interactive modes. Other small fixes are included, related to the size of the fields in the database. (Bitbake rev: 5e0bf388f4e5c1cc493ac8264785e631bad2f672) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-05-29bitbake: toaster logger: refactor recipe and layer file pathsAlexandru DAMIAN
This refactoring brings the "local_path" of the layer from the Layer object to the Layer_Version object, which is more appropriate as different checkouts of the same Layer may live in different directories. This enables us to store Recipe file paths relative to a Layer_Version at all times, aleviating the need to store full file paths in the database. We also turn the prefix of the path (e.g. virtual:native path name space) into a pathflag field. In turn, this solves the problem of mis-identification of tasks based on the recipe file paths, since we can also match the namespace of the file paths on the recipe files. [YOCTO #7594] (Bitbake rev: ec43dc569e370767c709dec225cbee0c99151c19) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-12-18bitbake: add build artifacts table and other improvementsAlexandru DAMIAN
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>
2014-11-28bitbake: toastergui: update layer search criteriaAlexandru DAMIAN
In order to accomodate the designs around imported layer, we add a "project" field for in the layer versions. The field must be set if and only if the layer is manually imported in the project. This will prevent information leakage between different projects. The views have been updated to perform relevant layer queries in a single location. (Bitbake rev: e1f7ec868b0702dfd27d5708581c134aaa6f4ae8) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-11-21bitbake: toastergui: layer name correlationAlexandru DAMIAN
This patch modifies how layers are identified and matched. Layers were primarely organized by the source of layer information, and Releases were separated by both layer git branches and originating source of layer information. This setup prevented mixing layers from different sources for a certain release, which didn't match the way people use Yocto Project / bitbake. This patch brings name-based indentification, where layers with the same name are assumed to be equivalent, in the sense of being able to substitute one another. To facilitate this identification to humans, layers are differentiated by GIT URI instead of layer sources, which was a rather arbitrary abstraction. Additional changes include modification to models in order accomodate for the new data structure, and to config file loading to match the new toasterconf.json layout. (Bitbake rev: 4357200aed522ad56cfd84917f877645b83b6a70) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-11-12bitbake: toaster: update Release model to pinpoint to specific BranchAlexandru DAMIAN
We update the release model to pinpoint to specific branch, instead of holding a branch name that needs to be matched. This is needed because we move away from mixing branches on different layer sources. Various minor changes to models file. (Bitbake rev: d58aacc69b1832f99758b941803123329e06082d) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-30bitbake: toaster: update web vcs fields for layersAlexandru DAMIAN
We update the layer vcs web fields to record extra URLs for directory and file viewing. Updating the layers view to show this data. (Bitbake rev: 14762e182c8af22fd0fa96f0ba0db1ecd2495fbc) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-10-30bitbake: toaster: improvements for admin pagesAlexandru DAMIAN
The default django URL validator marks git URLs as not valid, so we change the default validators to a URLValidator-derived that adds git and ssh protocol schemas and inhibits the frontend URL validator. We update the branch names based on the white-listed branch names in the Releases name. Adds proper class string to ease usage in admin section. Other small improvements. (Bitbake rev: 7d51f895bd56bd18f2258059b377851c2ce82114) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Conflicts: bitbake/lib/toaster/orm/admin.py Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-08-29bitbake: toaster: update orm models for layerindex compatibilityAlexandru DAMIAN
We add a ToasterSettings table that will keep installation-wide settings. We update the models for the layer-related data storage to make them compatible with the layerindex application API. We add a LayerSource class that can update local data from a LayerIndex-like compatible API. Adding a command line option to perform information update from all upstream layer sources. Fair warning - there is no backward migration from 0013. (Bitbake rev: 89e13579e1b44b738f10fadec8454aa0e6f073af) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-23bitbake: toaster: add project main edit pageAlexandru DAMIAN
This is the first commit on the project main edit page. At this point we have: * the default settings for a newly created project * the ability to add targets * the ability to trigger a build command, and have the build executed Project layers now have an optional field, allowing for removal. Default meta, meta-yocto and meta-yocto-bsp layers cannot be optional. We add XHR calls for interactivity in the main page. (Bitbake rev: 4e438854120cbd10319df1b571ec93e334002325) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-23bitbake: toaster: improved Project modelsAlexandru DAMIAN
A layer may live in a subdirectory of a git repository, so we add a field to track this setting in the Project layers. We add the Project schedule_build function, which creates a build request from the current project configuration. We also fix an import problem with Projects in views. (Bitbake rev: 1b5835e5d48cbfb7d38e38437c45d161052dfb37) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-14bitbake: toaster: new project page implementationAlexandru DAMIAN
We add the logic to create a new project. This page also serves as user registration and silent login for users. Once the project is added, the main project page is displayed. (Bitbake rev: 8855daebe55917c4f5855413d02ae1f3f7f76571) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-07-04bitbake: toaster: fix no newline at end of fileRobert Yang
Add a '\n' to the last line of the file to fix: No newline at end of file (Bitbake rev: 5eb65d92c35264087e5d82c35638f3b8805b1b3e) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-11bitbake: toaster: add Project class models to ormAlexandru DAMIAN
This patch adds the Project class models to the toaster GUI data model. There is no specified use, and the link in the Build class is optional. (Bitbake rev: 38f77a43d16e202d1f40632b27cb70dd20d02a5e) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-05-08bitbake: toaster: modify SQL data type constraintsAlexandru DAMIAN
This patch modifies the data type constraints for the SQL fields. The original constraints have been based on guess worked, and they weren't strictly enforced for sqlite. On MySQL, the constraints are strictly enforced, and need to match the real data that we have. After measuring data on sample builds, the new constraints have been validated to work with MySQL, and this patch updates the database schema with the new field types / constraints. (Bitbake rev: aaefbc0b4e7484d6f4854ce49602821a6e4adc4b) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-05-08bitbake: toaster: fix migration code for MySQLAlexandru DAMIAN
This is a patch that fixes the 0004, 0005 migrations of the toaster model to get them to properly work with MySQL. These migrations had a conflict around Build.timespent field. The sqlite3 constraits were not enough to detect the conflict, and the migrations worked as expected. MySQL objected to adding the field twice, so I did regenerate the migrations with the correct model listing. The net effect is the same, so the migrations work the same, but now we can use these two migration on the MySQL and other more advanced SQL engines. (Bitbake rev: 29afc29154b948d270ce52978a1eed4cd8887f92) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-04-04bitbake: toaster: fix help texts not showing for most tasksPaul Eggleton
These were not being collected properly because we were explicitly excluding variables defined as functions from being stored in the database. We don't want these to be shown in the variables list, and in any case it makes sense for these to be stored elsewhere, so create a separate model to store these. Fixes [YOCTO #6050]. (Bitbake rev: 0d76a5461ce4bd554ff70a465064969e53edf0a4) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-11bitbake: toaster: update database schemaAlexandru DAMIAN
This is a schema update to account for * relaxing constraints in Target_Image_File table * modifying permission filed to string value * adding license_manifest_path field * adding image_size field (Bitbake rev: f8488845ee9670e16a63c331dd2e97fdb314929c) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-09bitbake: toaster: update database schemaAlexandru DAMIAN
This patch updates the database schema to resolve a number of issues discovered while implementing the UI interface. We do not expect that all the data will come in valid at this point. [YOCTO #5453] [YOCTO #5833] [YOCTO #5836] [YOCTO #5811] [YOCTO #5812] [YOCTO #5820] (Bitbake rev: f8ad96d10a095e21fd2ce424c45e17f54642fb54) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-01-27bitbake: toaster: fix package data gatheringAlexandru DAMIAN
Under OE-Core, the name under which a package would be installed in a target may have been different than the name under it has been built or recorded in the dependencies listings. This patch addresses the way that Toaster records package names, and adds the field of "installed_name" to save the name under which a package have been installed in an image. (Bitbake rev: 24e0367429b248108b104ab5a2af05efcf7a8c39) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-01-27bitbake: toaster: Toaster GUI Build and Dashboard pages fixesAlexandru DAMIAN
THis is a large set of fixes for the generic table, Build and Dashboard pages. Among the fixes: * the table remembers which columns to show across refreshes, based on saving the settings in a cookie * added column timespent for a build which is a denormalization of the completed_on - started_on information due to limits in computing datetime differences in the SQL engine * fixed formatting of the time differences * various sorting header links fixed * correct error and warning CSS classes applied to the respective rows * fixes multiple divide-by-zero error in displaying duration estimations (Bitbake rev: 61e3dee55ac577fce1c0ae0fe7e0d3cf644e8ae6) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-12-10bitbake: toaster: migrate orm models to SouthAlexandru DAMIAN
As Toaster advances, database schema alteration will force users to delete old versions and lose all data collected. In order to prevent this, and to allow database updates to happen without having to delete old data, we use South to handle migrations for the ORM application which stores the Toaster data. [YOCTO #5559] (Bitbake rev: 6936faed8d94f3a2ab4055049cd27d02d8229003) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>