def _getattr_path(obj, path):
if not path:<EOL><INDENT>return None<EOL><DEDENT>for attr in path.split('<STR_LIT:.>'):<EOL><INDENT>obj = getattr(obj, attr, None)<EOL><DEDENT>return obj<EOL>
getattr for a dot separated path

If an AttributeError is raised, it will return None.