Normally, I code as follows for getting a particular item in a variable as follows
try: config = ConfigParser.ConfigParser() config.read(self.iniPath
I managed to get an answer, but I expect there should be a better one.
dictionary = {} for section in config.sections(): dictionary[section] = {} for option in config.options(section): dictionary[section][option] = config.get(section, option)