layerindex-web/layerindex
Robert Yang 635187b594 update_layer.py: avoid calling setup_core_layer_sys_path() when --initial
Fixed:
$ update.py -b <new_branch>
[snip]
NOTE: Starting bitbake server...
Traceback (most recent call last):
  File "update_layer.py", line 471, in main
    utils.setup_core_layer_sys_path(settings, branch.name)
  File "/buildarea1/lyang1/layerindex-web/layerindex/utils.py", line 376, in setup_core_layer_sys_path
    core_layerdir = os.path.join(core_repodir, core_layerbranch.vcs_subdir)
AttributeError: 'NoneType' object has no attribute 'vcs_subdir'
[snip]

This is because core_layerbranch is not in database yet for completely new
branch, so it is None and we will get the error. Avoid calling
setup_core_layer_sys_path() when "update_layer.py --initial" will fix the
problem.

And also only add core layer's sys path when it is present, since core layer
may not be added yet for completely new branch.

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2018-07-09 13:46:08 +02:00
..
migrations Implement patch tracking 2018-05-04 23:57:53 +12:00
static rrs: Set of UI improvments 2018-05-04 23:57:51 +12:00
templatetags templatetags/addurlparameter: remove unused reference 2018-04-24 10:15:47 +12:00
tools Implement layer web repo commit URL 2018-05-04 23:57:53 +12:00
__init__.py Initial commit of layerindex-web 2013-02-13 12:09:57 +00:00
admin.py Implement patch tracking 2018-05-04 23:57:53 +12:00
bulkchange.py bulkchange.py: use oe.recipeutils code to patch recipes 2018-05-01 10:10:01 +12:00
context_processors.py Add a link from the Tools drop-down to the RRS if enabled 2018-05-04 23:57:53 +12:00
forms.py Implement layer web repo commit URL 2018-05-04 23:57:53 +12:00
layerconfparse.py layerconfparse.py: remove unused layerbranch from parse_layer() 2017-07-21 08:14:57 +02:00
models.py rrs: default python2/3 environments for new maintenance plan layer branches 2018-05-04 23:57:53 +12:00
querysethelper.py Replace usage of model._meta.get_all_field_names() 2018-04-24 10:15:47 +12:00
recipedesc.py layerindex: Update tinfoil to call shutdown method 2017-01-11 21:56:35 +13:00
recipeparse.py utils: add common function to check out a specific git revision 2018-05-04 23:57:53 +12:00
restperm.py expose REST API for layerindex 2014-09-24 11:32:34 +01:00
restviews.py restviews: add additional layer view with extra nested fields 2018-02-07 11:27:48 +13:00
simplesearch.py Improve recipe search 2013-02-19 17:22:45 +00:00
tasks.py Asynchronous email notifications, task execution 2017-09-01 16:59:43 +12:00
update_layer.py update_layer.py: avoid calling setup_core_layer_sys_path() when --initial 2018-07-09 13:46:08 +02:00
update.py Move run_command_interruptible() to utils 2018-05-04 23:57:53 +12:00
urls_branch.py Add CSV export for layer recipes 2018-05-07 15:30:04 +12:00
urls.py Drop old raw recipe export code 2018-05-07 12:01:12 +12:00
utils.py update_layer.py: avoid calling setup_core_layer_sys_path() when --initial 2018-07-09 13:46:08 +02:00
views.py Add CSV export for layer recipes 2018-05-07 15:30:04 +12:00