After
5ace82e65c72847fb875fc01c419937a26a59d70 was merged, I found
three more instances of the code being patched.
The commit message of
5ace82e65c72847fb875fc01c419937a26a59d70 was/is:
"The default values are handled by mgr_module.py's _get_module_option();
the or here means that we break any non-true (0, false, none) value and
override it with the default."
Fixes: 5ace82e65c72847fb875fc01c419937a26a59d70
Fixes: https://tracker.ceph.com/issues/43746
Signed-off-by: Nathan Cutler <ncutler@suse.com>
(cherry picked from commit
30585f44de6147c824ed2df1a477ad17f7b51fff)
Conflicts:
src/pybind/mgr/osd_support/module.py
- file does not exist in nautilus
for opt in self.MODULE_OPTIONS:
setattr(self,
opt['name'],
- self.get_module_option(opt['name']) or opt['default'])
+ self.get_module_option(opt['name']))
self.log.debug(' %s = %s', opt['name'], getattr(self, opt['name']))
def _status(self, cmd):
for opt in self.MODULE_OPTIONS:
setattr(self,
opt['name'],
- self.get_module_option(opt['name']) or opt['default'])
+ self.get_module_option(opt['name']))
self.log.debug(' %s = %s', opt['name'], getattr(self, opt['name']))
def handle_command(self, _, cmd):