Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to update on server 2012 r2 via scheduled task. #16662

Closed
MrStonedOne opened this issue Jun 6, 2018 · 9 comments
Closed

Unable to update on server 2012 r2 via scheduled task. #16662

MrStonedOne opened this issue Jun 6, 2018 · 9 comments

Comments

@MrStonedOne
Copy link

@MrStonedOne MrStonedOne commented Jun 6, 2018

See topic.

It downloads the new one and creates the batch script and does something to trigger the batch script to be ran, but the lock for youtube-dl stays open while the batch script runs so it fails to update.

@MrStonedOne
Copy link
Author

@MrStonedOne MrStonedOne commented Jun 6, 2018

The only true fix is to allow -U to be passed a argument with the name of the binary to update, so the updater and updatee can be different binaries.

@MrStonedOne
Copy link
Author

@MrStonedOne MrStonedOne commented Jun 6, 2018

also: is there a way to force an update? I can't test this on the latest version because its. well, the latest version.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Jun 8, 2018

-U updates just fine. youtube-dl is not responsible for work of any other updating mechanism. You can't force update on up-to-date version.

@MrStonedOne
Copy link
Author

@MrStonedOne MrStonedOne commented Jun 9, 2018

youtube-dl is not responsible for work of any other updating mechanism.

A scheduled task is a windows subsystem to run a command at a certain time, the command it runs is youtube-dl -U, this does not work because youtube-dl's lock on itself never releases.

Please read bug reports before closing. For bonus points, its generally considered rude and bad form to close a issue report before follow up questions are asked and answered.

@remitamine @rg3 @dstftw Re-open please.

@rg3
Copy link
Collaborator

@rg3 rg3 commented Jun 9, 2018

Unable to reproduce. youtube-dl.exe -U works fine here from the command line under Windows 10. You can download older versions from here to test:

https://github.com/rg3/youtube-dl/releases

I set up a scheduled task to run youtube-dl.exe -U and it finished successfully, using an older version. After that, I checked and the binary had been updated.

@MrStonedOne
Copy link
Author

@MrStonedOne MrStonedOne commented Jun 9, 2018

alright, but I strongly suggest you add a way to force an update, as its the only way to test the current version and any issue i'm having could easily be some old bug since the version I was trying to update from was nov2017.

@lvqcl
Copy link

@lvqcl lvqcl commented Jun 9, 2018

since the version I was trying to update from was nov2017

Download and test previous version (2018.06.02, 8 days ago)?

@MrStonedOne
Copy link
Author

@MrStonedOne MrStonedOne commented Jun 10, 2018

And what happens when its a bug that was fixed in the current version?

Like is it really that controversial that having a part of your code that literally can't be tested is bad?

@rg3
Copy link
Collaborator

@rg3 rg3 commented Jun 24, 2018

NB: I stepped down as the maintainer several years ago, so what I say here is just my opinion.

I don't think it's controversial. Thing is, the hard part about updating to a newer version is overwriting the binary in place. In Python, downloading and reading an HTTP or HTTPS URL is almost trivial, so testing that case is not representative of the whole upgrade process working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.