bitbake-setup: Add strip to value from settings.conf
PATCH v4 1/1 bitbake-setup: Add strip to value from settings.conf
If user add "" to dl-dir as DL_DIR, it will show FetchError as following.
raise FetchError("Unable to fetch URL from any source.", u)
bb.fetch2.FetchError: Fetcher failure for URL: 'git://git.openembedded.org/bitbake;protocol=https;rev=master;branch=master;destsuffix=bitbake'. Unable to fetch URL from any source.
But from this log, user can't locate the real reason which is that the path "/aa/bb" is invalid.
So I make this fix, even if user add "" to dl-dir, the dl-dir will be the valid path. Other settings value also need this fix.
Signed-off-by Liu Yiding <[email protected]>
--- bin/bitbake-setup | 5 +++++ 1 file changed, 5 insertions(+)
bin/bitbake-setup +5 -0
@@ -920,6 +920,11 @@ def load_settings(settings_path): if os.path.exists(settings_path): logger.info('Loading settings from {}'.format(settings_path)) settings.read_file(open(settings_path)) + + for section in settings.sections(): + for key, value in settings[section].items(): + settings[section][key] = value.strip('\"\'') + return settings def change_setting(top_dir, args):
Signature · 1 line
2.43.0