aioftp
aioftp copied to clipboard
Multiplex download
I was somehow expecting (mostly due to experience with async HTTP clients) to be able to use the same client instance to create multiple concurrent downloads. However, when I attempt this I get an error like
readuntil() called while another coroutine is already waiting for incoming data
Is this expected not to work or is there a problem with my code doing the downloading?
Would it work with multiple client instances or would they have to run in separate processes?
FTP differs from HTTP very much. It has one long-playing command connection. So if you want multiple streams, then you need multiple clients. But I don't see any effort of this, since it is, anyway, will be network-bounded task.
Okay, thanks! I have many small files to download so I don't think there is an issue with limited bandwidth on each file.
@Midnighter perhaps this example will help you: https://stackoverflow.com/a/73871567
Cheers, thank you for the hint. I should close this issue anyhow, since it's no longer a problem for me.