diff --git a/pydrive2/fs/spec.py b/pydrive2/fs/spec.py index 997b0a5e..c5abe03d 100644 --- a/pydrive2/fs/spec.py +++ b/pydrive2/fs/spec.py @@ -473,6 +473,11 @@ def find(self, path, detail=False, **kwargs): bucket, base = self.split_path(path) seen_paths = set() + cached = base in self._ids_cache["dirs"] + if not cached: + dir_ids = self._path_to_item_ids(base) + self._cache_path_id(base, *dir_ids) + dir_ids = [self._ids_cache["ids"].copy()] contents = [] while dir_ids: