websemantics / vimeo-upload

Upload videos to your Vimeo account and update their metadata directly from a browser or a Node.js app

Home Page:http://websemantics.github.io/vimeo-upload/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ERR_CONNECTION_RESET, When will upload via chunks be available?

rottenoats opened this issue · comments

Unsure if the two are related, however on some computers I'm getting an ERROR_CONNECTION_RESET while uploading videos that are greater than 2-3G via Chrome.

There is a way to fix this via Chrome, however it's not very user-friendly since I'm looking to create a video uploader for video contributors to my channel.

When will the upload via chunks be available ? Would be nice to catch this error and switch to upload via chunks?

Thanks !

I believe chunks upload is to enable pause / resume and not sure if that would solve uploading large files. Don't have plans for implementing this atm, put would welcome any contributions,

Hey, thanks for the response. I'll look into it and if I find a solution I'll contribute.
Also wanted to know if there is a way to have it upload in chunks by default to be able to test to see if the error still shows up?

@websemantics I forgot to get back to you, but I created a typescript project based off of your vimeo-upload. It uploads purely by chunks (and updates the chunk size based on the connection speed). If you're interested in using it, I could eventually submit a pull request. It could be seen a v2 of your original project. However, I'd have to change a few things to make it more dynamic.

Hi @rugdealer,
That would be a great contribution initially as a usage example then as an integral part of the plugin. Does this have a progress indicator? as a callback function maybe?
All the best,

@websemantics
Yes, it actually has two progress indicators. One for the chunk upload and one for the total upload. You can check out a version I pushed two months ago https://github.com/rugdealer/vimeo-upload . I changed a few things for the company I work for.

I'll prepare an easier version to use. I'll keep you posted.

In the index.html, it's pretty much the same thing you do.

function handleFileSelect(evt){
            evt.stopPropagation();
            evt.preventDefault();
            var files = evt.dataTransfer ? evt.dataTransfer.files : $(this).get(0).files
            vs.bindChunkProgressBar(document.getElementById('progress_partial'));
            vs.bindProgressBar(document.getElementById('progress'));
            vs.bindEstimatedTimeElem(document.getElementById('results'));
            vs.start({
                file: files[0]
            });
        }

Edit

Yeah, i'll add some interfaces and make it all round cleaner. I'm using a cleaner version for the company. It works well. Tested it with a 20g file without getting any errors.

commented

I am also using a slightly modified version of vimeo-upload in production and am very interested in the ability to upload via chunks. Right now not all my client's large file uploads go through, most often on the clients with poorer internet connections.

I'd be happy to put together a PR, let me know.

I will look forward to your PR @rugdealer, this is exciting 👍
@jehartzog hi, do you want to wait until we have @rugdealer PR? it sounds fully featured,

commented

I'll definitely wait, but just letting you know I'll be testing and possibly pushing to production when ready, so can help out whenever needed.

I've modified quite a bit with the project. I'm currently debugging and I expect the first version of the project to be finished in a few days. How should we handle the PR? Should a branch be created? The tricky part is, it's a project started from scratch so it uses a completely different .git. Should the project be completely separate and renamed "vimeo-chunk-upload" ? Please let me know what you think would be best @websemantics thanks.

EDIT: I also need to finish documentation and code commenting.

@rugdealer, I don't mind having own fork vimeo-chunk-upload and I'll surely link it from README.md for the benefit of interested developers,

I've created a new branchchunk-upload in case you'd like to integrate with the current codebase (fork, update, PR). Like you mentioned, adding docs and updating demo code for other developers to fully take advantage of this new feature is preferred,

If you do go with the later, make sure you add yourself to the authors list (i.e. package.json etc) as this is a major contribution and since your help will also be needed to fix any bugs :)

@websemantics ok great. I've forked the project and started adding the changes. I'll send the pull request in a few days to your chunk-upload branch.