From 1c9aef07fcbc3ad5c35b9e8a727733999fdb16cb Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Mon, 10 May 2021 10:12:11 +0800 Subject: [PATCH] doc/_ext: use str for mgr module options by default sometimes, they don't specify the option type and just default to "str". Signed-off-by: Kefu Chai --- doc/_ext/ceph_confval.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/_ext/ceph_confval.py b/doc/_ext/ceph_confval.py index 72a10aa59930..8883f4f5d9be 100644 --- a/doc/_ext/ceph_confval.py +++ b/doc/_ext/ceph_confval.py @@ -350,6 +350,9 @@ class CephOption(ObjectDescription): opt = self._load_yaml().get(name) if opt is None: raise self.error(f'Option "{name}" not found!') + if cur_module and 'type' not in opt: + # the type of module option defaults to 'str' + opt['type'] = 'str' desc = opt.get('fmt_desc') or opt.get('long_desc') or opt.get('desc') opt_default = opt.get('default') default = self.options.get('default', opt_default) -- 2.47.3