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

DownloadFromRemote does not seem to work #46

Closed
cdoern opened this issue Jul 3, 2021 · 4 comments
Closed

DownloadFromRemote does not seem to work #46

cdoern opened this issue Jul 3, 2021 · 4 comments

Comments

@cdoern
Copy link

cdoern commented Jul 3, 2021

Hello, trying to copy a .tar archive from my remote client and I consistently get Error: timeout when download files any idea what causes this error? Any feedback or changes would be appreciated

@bramvdbogaerde
Copy link
Owner

Can you give me a bit more information about how you are trying to use the library?

  • What authentication method do you use?
  • Which function did you use for copying the files from the remote (there are a couple with varying degrees of flexibility)
  • How large is the file you are trying to copy?
  • Does the name of the file contain any special characters or spaces?

I know it is not always possible to provide a file, but it would be very useful to me to get an example file so that I can try to reproduce the bug locally.

Thanks for reporting!

@levwz
Copy link

levwz commented Jul 15, 2021

Hello, trying to copy a .tar archive from my remote client and I consistently get Error: timeout when download files any idea what causes this error? Any feedback or changes would be appreciated

Please try set a long and reasonable Timeout after scp client created, this solved my issue.
client.Timeout=36000000000000

@bramvdbogaerde
Copy link
Owner

I think there are two possible ways to resolve this issue (in terms of improvements of the library):

  • Disable the timeout by default and make it so that it needs to be explicitly enabled
  • Increase the the default timeout to something more than a single minute since larger files tend to take more than a minute to be transfered

However, in my opinion the current implementation of the timeout is rather flawed. I would expect that a timeout is only triggered when the client has waited for a long period of time without receiving any data. In the current implementation, the timeout is simply a timer that expires after one minute in which case the error is thrown.

Thoughts?

@bramvdbogaerde
Copy link
Owner

Closing in favor of #47 .

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