def METHOD_NAME(self, path):
    path = self.resolve(path)
    pathset = set(path.parents)
    pathset.add(path)
    # yield any tracked folders that contain the target path
    yield from pathset & self.black
    yield from pathset & self.grey