fsspec / fsspec/filesystem_spec
find stores only last walked path
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.4k
- Forks
- 490
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 38
Description
I have not found consequences of that yet, however find only writes the last walked path to out:
for path, dirs, files in self.walk(path, maxdepth, detail=True, **kwargs):
if withdirs:
files.update(dirs)
out.update({info["name"]: info for name, info in files.items()})
if self.isfile(path) and path not in out:
# walk works on directories, but find should also return [path]
# when path happens to be a file
out[path] = {}
I guess either _path or an indent was intended.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at fsspec/spec.py:427 and inspect find's loop over walk(...), especially how path and out are updated across multiple iterations. Verify the behavior with multiple walked paths and check for existing find coverage. Done means find returns entries from every walked path rather than only the last path.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100