Issue 14388: configparser.py traceback - Python tracker (original) (raw)

This seems like it could be user error, but the traceback doesn't provide useful information on where the problem could be. The relevant class is at the following URL.

https://github.com/Bcfg2/bcfg2/blob/master/src/lib/Server/Plugin.py#L1180

Traceback (most recent call last): File "/root/bcfg2/Bcfg2/Server/FileMonitor.py", line 64, in handle_one_event self.handles[event.requestID].HandleEvent(event) File "/root/bcfg2/Bcfg2/Server/Plugins/Packages/PackagesSources.py", line 52, in HandleEvent self.pkg_obj.Reload() File "/root/bcfg2/Bcfg2/Server/Plugins/Packages/init.py", line 193, in Reload self._load_config() File "/root/bcfg2/Bcfg2/Server/Plugins/Packages/init.py", line 203, in _load_config self._load_sources(force_update) File "/root/bcfg2/Bcfg2/Server/Plugins/Packages/init.py", line 221, in _load_sources if not self.disableMetaData: File "/root/bcfg2/Bcfg2/Server/Plugins/Packages/init.py", line 65, in disableMetaData return not self.config.getboolean("global", "resolver") File "/root/bcfg2/Bcfg2/Server/Plugin.py", line 1216, in getboolean section, option) File "/usr/lib64/python3.2/configparser.py", line 819, in getboolean raw=raw, vars=vars) File "/usr/lib64/python3.2/configparser.py", line 793, in _get return conv(self.get(section, option, **kwargs)) TypeError: get() got an unexpected keyword argument 'raw'

Please let me know if more information is required.

Looking at the traceback and your code, configparser is calling 'get', expecting to call its own get method (that takes a 'raw' keyword), but instead is calling the get on your subclass, which doesn't take a 'raw' keyword.

Since this appears to be example code, probably what you should do to fix this is remove those get methods. Your 'default' is spelled 'fallback' in Python3.2 configparser and does the same thing your code does.