[Toaster] [review-request][PATCH 0/6] Fix handling of "default" project
Elliot Smith
elliot.smith at intel.com
Fri Aug 28 05:59:10 PDT 2015
This fixes how we handle the default project used to house command
line builds. It originally started from a bug encountered when
using MySQL for the db back-end, but fixing that revealed some
other issues which needed to be resolved on top.
Instead of relying on an ID of 0 as being the identifier for the
default project, use an explicit is_default flag in the project table.
Because the default project is now added when the db for the app
is initialised, this required some changes to how we manage
project visibility and landing page redirects based on the state
of projects and builds.
Changes since poky master 393bd7496d71eb101f21234c1233a2d18fd2c73e are in
git://git.yoctoproject.org/poky-contrib, elliot/toaster/mysql-migrations
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=elliot/toaster/mysql-migrations
Related bug: https://bugzilla.yoctoproject.org/show_bug.cgi?id=7932
Elliot Smith (6):
toaster: Make 0021 migration compatible with MySQL
toaster: Improve how default project is identified and fetched
toaster: Only redirect to projects page if user has added projects
toaster: Exclude default project unless it has builds
toaster: Fix test for projects page JSON
toaster: Add tests for pages which show the default project
bitbake/lib/bb/ui/buildinfohelper.py | 3 +-
...ect__chg_field_project_bitbake_version__chg_.py | 4 +-
.../0025_auto__add_field_project_is_default.py | 339 +++++++++++++++++++
.../orm/migrations/0026_add_default_project.py | 357 +++++++++++++++++++++
bitbake/lib/toaster/orm/models.py | 18 +-
bitbake/lib/toaster/toastergui/tests.py | 124 ++++++-
bitbake/lib/toaster/toastergui/views.py | 14 +-
7 files changed, 846 insertions(+), 13 deletions(-)
create mode 100644 bitbake/lib/toaster/orm/migrations/0025_auto__add_field_project_is_default.py
create mode 100644 bitbake/lib/toaster/orm/migrations/0026_add_default_project.py
--
Elliot Smith
Software Engineer
Intel OTC
---------------------------------------------------------------------
Intel Corporation (UK) Limited
Registered No. 1134945 (England)
Registered Office: Pipers Way, Swindon SN3 1RJ
VAT No: 860 2173 47
This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
More information about the toaster
mailing list