Learn how to make the most out of the Dropbox Community here 💙.
Learn how to make the most out of the Dropbox Community here 💙.
GREG! Thank you so much for answering.
Yes, just created a live page for you to test.
https://www.nebula.my/greg-db
It uses the exact same code I showed in my post, just substituted my access token with the input.
Thanks! I just tried this out but I don't see the "ERR_INVALID_HANDLE" error you mentioned, when attempting to upload a file larger than 150 MB. What browser/version are you using?
I do notice that you don't seem to be sending the session ID up properly on the /append_v2 calls. The parameters being sent look like:
{"cursor": {"session_id": "undefined","offset":"8000000"},"close":false}
So, it seems you have a bug when you get or set the session ID. You'll need to make sure you supply that session ID value (as returned by /start), not undefined.
The ERR_INVALID_HANDLE comes from here, when you mouse over the Status column of the request.
I'm currently using Google Chrome - Version 89.0.4389.114 (Official Build) (64-bit)
Thanks Greg! I'll go fix that right away.
However, would the incorrect session_id header explain the Start session failing as well?
I see, thanks for clarifying. No, that wouldn't explain /start failing, since /start itself returns the session ID to begin with. I happened to be testing in Firefox, where the /start call did work successfully for me (and still does).
Trying in Chrome now though, I can reproduce this issue. I'm not sure exactly why this is failing in Chrome but not Firefox, but as this is apparently due to some different in how Chrome itself handles this, as opposed to the Dropbox API itself, I may not be able to offer much help.
I notice that the call to /2/files/upload (for smaller files) does work in Chrome though. As a next step in debugging this, I recommend looking into what the difference is in your implementation for these different calls. It's difficult to see exactly what there is in the code on my side since it's minified, but it looks like you're doing a "return fetch..." for /2/files/upload, but don't have the "return" for /2/files/upload_session/start. Likewise, you seem to be manually specifying "Content-Length" for /2/files/upload_session/start but not for /2/files/upload.
Hey Greg-DB , thanks for the insight, I'll give FireFox a try as well.
As for the inconsistencies on my the two different fetches, I'm just desperate right now so I'm adding and removing parts of the fetch to see if it makes any difference. Since it threw a TypeError, I thought perhaps it had something to do with my syntax. As in my original post, I've tried to keep the two fetches as consistent as possible but still nothing unfortunately.
Thank you so much for taking the time to check this out, Greg-DB . Greatly appreciate it!
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 or Facebook.
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!