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

pull_path doesn't retrieve empty directories #968

Closed
benhoyt opened this issue Jul 10, 2023 · 0 comments · Fixed by #1024
Closed

pull_path doesn't retrieve empty directories #968

benhoyt opened this issue Jul 10, 2023 · 0 comments · Fixed by #1024
Assignees
Labels
bug Something isn't working small item

Comments

@benhoyt
Copy link
Collaborator

benhoyt commented Jul 10, 2023

Per this comment, Container.pull_path doesn't retrieve empty directories. This seems like a bug, not a feature (Git's behaviour notwithstanding). From a quick look at the code, I think push_path will have a similar problem.

We probably need to change the _list_recursive helper to also yield directories (before recursing), and the callers test if it's a directory and create it, otherwise copy the file.

@benhoyt benhoyt added bug Something isn't working and removed good first item labels Sep 29, 2023
benhoyt pushed a commit that referenced this issue Oct 4, 2023
Instead of just recursively iterating through the remote/local files,
also iterate through the directories as well, ensuring that they are
created even if they don't contain any files.

Also create/update relevant test cases.

Fixes #968
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working small item
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants