def from_pyfile(self, filename):
module = types.ModuleType('<STR_LIT>')<EOL>module.__file__ = filename<EOL>try:<EOL><INDENT>with open(filename) as config_file:<EOL><INDENT>exec(compile(config_file.read(), filename, '<STR_LIT>'),<EOL>module.__dict__)<EOL><DEDENT><DEDENT>except IOError as e:<EOL><INDENT>e.strerror = '<STR_LIT>' % e.strerror<EOL>raise<EOL><DEDENT>self.from_object(module)<EOL>return True<EOL>
Update the values in the config from a Python file.
        Only the uppercase variables in that module are stored in the config.

        :param filename: an absolute path to the config file