def import_by_path(path):

    """Append the path to sys.path, then attempt to import module with
    path's basename, finally making certain to remove appended path.

    http://stackoverflow.com/questions/1096216/override-namespace-in-python"""

    sys.path.append(os.path.dirname(path))
    try:
        return __import__(os.path.basename(path))
    except __HOLE__:
        logger.warn('unable to import {0}'.format(path))
    finally:
        del sys.path[-1]
dataset/ETHPy150Open quaddra/provision/provision/config.py/import_by_path