import sys sys.path.insert(0, '..') class Config(dict): def __init__(self, fname): data = open(fname).read() exec(data, dict(), self)