We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
barry m.10
10 years agoNew member | Level 1
dbx.files_upload raises ('Connection aborted.', BadStatusLine("''",))
Hi,
I am unable to upload using your Files_upload function. It fails with the following error:
requests.exceptions.ConnectionError: ('Connection aborted.', BadStatusLine("''",))
I am on Windo...
barry m.10
10 years agoNew member | Level 1
thanks for your assistance Gregory
<< As far as the BadStatusLine issue is concerned, can you try opening the file in binary mode and let me know if that doesn't help?>>
Yes, that fixed it. Who should be advised that the Python example program which is provided has a bug? Statement 21 at https://github.com/dropbox/dropbox-sdk-python/blob/master/example/back-up-and-restore/backup-and-restore-example.py
Also, could the error handling be improved? The current exception is not helpful to identify the problem.
<<the first parameter to files_upload should be "A string or file-like obj of data.">>
Yes, I had read that. The documentation could be improved IMO. The name of the function is files-upload. My error I know, but I was blind-sided by that, and was thinking that the function only dealt with files.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!