Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code duplication: datachain.lib.listing should use Client.scandir() #373

Closed
rlamy opened this issue Aug 28, 2024 · 0 comments · Fixed by #376
Closed

Code duplication: datachain.lib.listing should use Client.scandir() #373

rlamy opened this issue Aug 28, 2024 · 0 comments · Fixed by #376

Comments

@rlamy
Copy link
Contributor

rlamy commented Aug 28, 2024

datachain.lib.listing contains a partial copy of the code used by Client.scandir(), which only includes a generic version of the "nested" algorithm. This has some disadvantages:

A quick fix is to convert list_bucket() into a wrapper around Client.scandir(), converting the Entry objects the latter returns into File, but it shouldn't be hard to make Client.scandir() return File directly, as already planned in #33.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant