On Fri, Jan 01, 2016 at 02:05:34PM -0500, Karl Dahlke wrote: > > Yeah that makes sense actually, but what do we do with the download > > in the meantime? > > I'm not sure if we should just pause waiting or not. > > No I don't think that's good. > Servers will time out etc. > Nor do I think we should start writing to a temp file and move data around later. I agree none of these solutions are ideal but I'm not sure about the correct solution here. > I can tell you what we do today and hope that helps. > I analyze the headers as they come in and compare them > against standards and plugins etc. > If it is not text, and not something you know you want to download to play > as a plugin, say usually some kind of binary, > then I stop the download after the headers, > as though it were a HEAD call. > There's a curl command to stop the download gracefully. > Once I know where to send the data, I restart the call. My issue here is with any fancy redirects we may encounter. Theoretically they should work but I can think of cases where this may break when we try and restart the download. > I get the headers and the data and into the file it goes > and it all works without trouble. Agreed. > I imagine edbrowse-curl would analyze the headers as we do now, > and if a potential download, it sends the message back to edbrowse and stops. > Then edbrowse sends message back restarting the download > into the designated file, > thus the different messages: fetch generic and fetch into a named file. I'd rather not do the restart if at all possible. I'd rather download and move data, that's not too bad. May be we have a maximum grace time after which we stop, but I'd rather not just stop the download. Or work out how to do either a head call for http or an ftp call (I'm fairly sure I've seen one) since any server *should* support that. > Sure, I'll work on some different progress options, > including quiet, no progress indicators at all, > just the file size when done. The more I think about it, the more i like the 7/235 megabytes option printed at a fixed rate. If we can also get status into the background download monitoring as well that'd be great. > I'm happy to work on little features in parallel, > and there seems to be plenty of them. Brilliant, thanks. Cheers, Adam. PS: I can't remember but I know we have a plugins off and plugins on, but do we have a plugins ask as well? There are times when I'd like to choose whether to use a plugin at the point of download.