@@ -781,10 +781,10 @@ class DataSmart(MutableMapping):
return None
cachename = var + "[" + flag + "]"
- if not expand and retparser and cachename in self.expand_cache:
+ if not expand and retparser and cachename in self.expand_cache and not noweakdefault:
return self.expand_cache[cachename].unexpanded_value, self.expand_cache[cachename]
- if expand and cachename in self.expand_cache:
+ if expand and cachename in self.expand_cache and not noweakdefault:
return self.expand_cache[cachename].value
local_var = self._findVar(var)
@@ -904,7 +904,7 @@ class DataSmart(MutableMapping):
value = bb.filter.apply_filters(value, [self.filters[basevar],])
parser.value = value
- if parser:
+ if parser and not noweakdefault:
self.expand_cache[cachename] = parser
if retparser:
The recently fragment error handling code uses noweakdefault=True to getVar. Unfortunately there is a bug where the expand cache may cause that value to ignored, giving confusing error messages. Avoid the expand cache if that parameter is used. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> --- lib/bb/data_smart.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)