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

Files from multiple folders #6

Open
cgriffith12 opened this issue Jan 10, 2020 · 2 comments
Open

Files from multiple folders #6

cgriffith12 opened this issue Jan 10, 2020 · 2 comments

Comments

@cgriffith12
Copy link

Thank you for the Lambda script. I am using the script to connect a FTP server and pull all the files into a S3 bucket, except all the files I need are in multiple folders so I keep getting errors downloading the files. the script tries to download the files and errors out because all the files I need are in folders in the remote path
Is there a way to pull files from multiple folders?

@orasik
Copy link
Owner

orasik commented Jan 13, 2020

you should be able to retrieve all folders if you add else for if statement at

        if not is_ftp_folder(ftp, file):

this will require rewriting the handler to be a function so it can be re-used in the else statement.

@bhouy
Copy link

bhouy commented Jan 29, 2020

Hello Orasik, This is really good stuff!
I am looking for the exact same things as cgriffith12. I apologize but I am new to python and can't seem to get this to work. Can you please show in detail how to add an else for if statement to your existing script? I also don't know what you mean by 'rewriting the handler to be a function'.

Any assistance would be greatly appreciated. Thanks mate!

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

No branches or pull requests

3 participants