Bug 5989 - Malformed string error on extra parameter
Summary: Malformed string error on extra parameter
Status: RESOLVED FIXED
Alias: None
Product: Hob
Classification: Build System, Metadata & Runtime
Component: hob (show other bugs)
Version: 1.6
Hardware: x86 x86_64
: Medium normal
Target Milestone: 1.6 M5
Assignee: Marius Avram
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2014-03-17 15:31 UTC by Lucian Musat
Modified: 2014-03-26 08:52 UTC (History)
6 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Don't know


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lucian Musat 2014-03-17 15:31:18 UTC
STATUS: IDLE
BUILD: 1.6_M4.rc1:1960f6b2ecbb793b40ebc9aed25c8f9cb7884c9a
ENVIRONMENT: Ubuntu 13.10 x86_64
STEPS TO REPRODUCE: 
  
launch hob

click "Settings"->"Others", add extra paramters as following for libx11

####
PREFERRED_PROVIDER_virtual/libx11 = "libx11-diet"
####


select one "Machine", for example, qemux86

choose one "Base image", for example, core-image-sato


build the recipe, libx11 and check if only libx11 is built out


EXPECTED OUTCOME: 
  
 User could set extra parameters in "Settings"->"Others".

Actual outcome:

Hob throws and error like this:

Traceback (most recent call last):
  File "/home/lucian/work/m4-rc1/poky/bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py", line 560, in settings_button_clicked_cb
    self.builder.reparse_post_adv_settings()
  File "/home/lucian/work/m4-rc1/poky/bitbake/lib/bb/ui/crumbs/builder.py", line 1308, in reparse_post_adv_settings
    self.populate_recipe_package_info_async()
  File "/home/lucian/work/m4-rc1/poky/bitbake/lib/bb/ui/crumbs/builder.py", line 547, in populate_recipe_package_info_async
    self.set_user_config()
  File "/home/lucian/work/m4-rc1/poky/bitbake/lib/bb/ui/crumbs/builder.py", line 723, in set_user_config
    self.set_user_config_extra()
  File "/home/lucian/work/m4-rc1/poky/bitbake/lib/bb/ui/crumbs/builder.py", line 707, in set_user_config_extra
    self.handler.set_extra_config(self.configuration.extra_setting)
  File "/home/lucian/work/m4-rc1/poky/bitbake/lib/bb/ui/crumbs/hobeventhandler.py", line 359, in set_extra_config
    old_extra_setting = ast.literal_eval(self.runCommand(["getVariable", "EXTRA_SETTING"]) or "{}")
  File "/usr/lib/python2.7/ast.py", line 80, in literal_eval
    return _convert(node_or_string)
  File "/usr/lib/python2.7/ast.py", line 79, in _convert
    raise ValueError('malformed string')
ValueError: malformed string


The error seems to be about the line added by it in local.conf:

#added by hob
EXTRA_SETTING = "{'PREFERRED_PROVIDER_virtual/libx11': 'libx11-diet'}"
Comment 1 Marius Avram 2014-03-25 13:52:43 UTC
Solution merged on poky:master, commit 41ed4123a687f77a2042cf50d89652639075f869
Comment 2 Lucian Musat 2014-03-26 08:52:29 UTC
Verified.
No more malformed string error when adding extra parameters.

Cheers