Evaluation of global symbols in list comprehension context (e.g. $(eval [arg(var) for var in ['fuga', 'arg']])) was failing:
AttributeError: '_DictWrapper' object has no attribute 'get'
Essentially, symbols need to be passed as the globals argument to eval() and this argument needs to inherit from dict.
Additionally, this PR improves the discarding of private symbols (starting with double underscore). Previously, any double underscores were considered offending, even those in the middle of a symbol or in literal text.
These are the same changes, I have implemented for xacro.
Evaluation of global symbols in list comprehension context (e.g.
$(eval [arg(var) for var in ['fuga', 'arg']])
) was failing:AttributeError: '_DictWrapper' object has no attribute 'get'
Essentially, symbols need to be passed as the
globals
argument toeval()
and this argument needs to inherit fromdict
.Additionally, this PR improves the discarding of private symbols (starting with double underscore). Previously, any double underscores were considered offending, even those in the middle of a symbol or in literal text. These are the same changes, I have implemented for
xacro
.