ansible-navigator icon indicating copy to clipboard operation
ansible-navigator copied to clipboard

Many params missing change after initial = False

Open cidrblock opened this issue 4 years ago • 1 comments
trafficstars

https://github.com/ansible/ansible-navigator/blob/9d00602cf6dd87c9c76df1d4e2ec0f7179096dab/ansible_navigator/configuration_subsystem/navigator_configuration.py#L294

Also the log message for "cannot be changed" in configurator should probably be DEBUG since, these always show and are not generated by any user input

cidrblock avatar Jun 02 '21 18:06 cidrblock

The configuration subsystem allows certain settings option to be flagged as change_after_initial True or False. (https://github.com/ansible/ansible-navigator/blob/main/src/ansible_navigator/configuration_subsystem/definitions.py#L76)

If the user specifies one of these options at the colon prompt and the particular setting cannot be changed after ansible-navigator has been initialized, a message is logged for the user: https://github.com/ansible/ansible-navigator/blob/0918b3c142fb6dc5d1d1aa5f9704434397edf6f3/src/ansible_navigator/configuration_subsystem/configurator.py#L131

One example of this is the no_color option, the colors are initialized when ansible-navigator starts up, and changing this setting later would have no effect: https://github.com/ansible/ansible-navigator/blob/0918b3c142fb6dc5d1d1aa5f9704434397edf6f3/src/ansible_navigator/configuration_subsystem/navigator_configuration.py#L225

All settings option should be reviewed and a determination made of what can be changed after initialization, for instance logging is setup early on and therefore cannot be changed, but is not flagged as such:

https://github.com/ansible/ansible-navigator/blob/0918b3c142fb6dc5d1d1aa5f9704434397edf6f3/src/ansible_navigator/configuration_subsystem/navigator_configuration.py#L325

https://github.com/ansible/ansible-navigator/blob/0918b3c142fb6dc5d1d1aa5f9704434397edf6f3/src/ansible_navigator/configuration_subsystem/navigator_configuration.py#L336

https://github.com/ansible/ansible-navigator/blob/0918b3c142fb6dc5d1d1aa5f9704434397edf6f3/src/ansible_navigator/configuration_subsystem/navigator_configuration.py#L343

cidrblock avatar Sep 27 '21 16:09 cidrblock