nunavut icon indicating copy to clipboard operation
nunavut copied to clipboard

Options not respected in config yaml but are respected as command line args

Open skeetsaz opened this issue 11 months ago • 1 comments

Looks like there's a bug where if you specify some options in a config yaml they will not be respected but the same options specified as command line args are.

Given config.yaml

nunavut.lang.cpp:
  options:
    enable_serialization_asserts: true

This does not work:

nnvg -Xlang --language-standard=cetl++14-17 -l=cpp --configuration=config.yaml <dsdl_root>

But this does:

nnvg -Xlang --language-standard=cetl++14-17 -l=cpp --enable-serialization-asserts <dsdl_root>

It appears to go off the rails here and overwrite what was specified in the config yaml: https://github.com/OpenCyphal/nunavut/blob/main/src/nunavut/lang/init.py#L321

# Now update the configuration for the target language with everything we stored in this
# builder instance...
self.config.update_section(
    LanguageClassLoader.to_language_module_name(target_language_name), self._target_language_config
)

skeetsaz avatar Feb 28 '24 21:02 skeetsaz

erp 😳

thirtytwobits avatar Feb 28 '24 21:02 thirtytwobits