'Clean out any expired/old codeintel information.'

def clean(self):

    base_dir = self.base_dir
    if (not exists(base_dir)):
        return
    for d in os.listdir(base_dir):
        path_path = join(base_dir, d, 'path')
        if (not exists(path_path)):
            continue
        path = codecs.open(path_path, encoding='utf-8').read()
        if (not exists(path)):
            log.debug('clean::    scanned    directory    no    longer    exists:    %r', path)
            rmdir(join(base_dir, d))
