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

Force update #7747

Closed
latot opened this issue Dec 3, 2015 · 12 comments
Closed

Force update #7747

latot opened this issue Dec 3, 2015 · 12 comments

Comments

@latot
Copy link

@latot latot commented Dec 3, 2015

Hi, well i'm here agin to ask a feature.
Its becasue for example if we download manually youtube-dl to a custom dir or in windows we do a bin path for linux apps it don't permit update via -U, this is the super message:

It looks like you installed youtube-dl with a package manager, pip, setup.py or 
a tarball. Please use that to update.

Thx.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Dec 3, 2015

What's your proposal?
If you've installed youtube-dl manually you'll be able to update with -U. If you installed it with any kind of package manager you should use it for updating since -U option may be removed by package maintainers at all.

@latot
Copy link
Author

@latot latot commented Dec 3, 2015

mm, a example wil be more easy, in windows. have a rute /hi/bin here i put my bineries of linux for windows like youtube-dl.exe.

so i download it and then i put the file in that directory.
The directory are in PATH env.

in a cmd i run
youtube-dl -U
and i get the message D:

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Dec 3, 2015

This is known bug.

@dstftw dstftw closed this Dec 3, 2015
@latot
Copy link
Author

@latot latot commented Dec 3, 2015

don't is that bug
is different, here youtube-dl detects the custom dir as a package manager installation, and i have write permiss.

@AGSPhoenix
Copy link
Contributor

@AGSPhoenix AGSPhoenix commented Dec 25, 2015

@dstftw, I think this is a different issue. This seems to be about youtube-dl thinking it was installed via package manager when it wasn't.

This seems to be the relevant code, though it has been so long since I've worked with the codebase that I'm not really sure how it behaves under each of the various distribution methods (compiled executable, source files, etc.).

@latot, what path is your youtube-dl installed in? I tried updating from C:\hi\bin without issue; was that just an example, or the actual path you're using? Are you sure you're using the prepackaged youtube-dl.exe and that there is no separate install from pip or setup.py?

@latot
Copy link
Author

@latot latot commented Dec 25, 2015

Hi, i test it with linux and windows, in windows i use this path this location /User/Cos/Documents/linux/bin in linux i try this but without path only running from terminal, /home/pipe/Documentos/youtube.dl (file)

i install both downloading from the instructions of main page, i don't install from pip, in windows i use the .exe version in the same page.

Cys.

@AGSPhoenix
Copy link
Contributor

@AGSPhoenix AGSPhoenix commented Dec 25, 2015

It works for me:

PS C:\Users\Phoenix\Documents\linux\bin> .\youtube-dl.exe -U -v
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'-U', u'-v']
[debug] Encodings: locale cp1252, fs mbcs, out cp437, pref cp1252
[debug] youtube-dl version 2015.12.21
[debug] Python version 2.7.10 - Windows-8-6.2.9200
[debug] exe versions: ffmpeg N-76776-g3c110b0, ffprobe N-76776-g3c110b0
[debug] Proxy map: {}
Updating to version 2015.12.23 ...
Waiting for file handle to be closed ...
PS C:\Users\Phoenix\Documents\linux\bin> Updated youtube-dl to version 2015.12.23.

Could you run the same command (youtube-dl.exe -U -v) and paste the output here?

@latot
Copy link
Author

@latot latot commented Dec 25, 2015

Hi, testing if i run the command from the directory it works, but calling with the PATH don't works (the rute of windows is in path).

don't working:

C:\Users\Cos>youtube-dl.exe -U -v
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-U', '-v']
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2015.01.11
[debug] Python version 3.4.2 - Windows-7-6.1.7601-SP1
[debug] exe versions: ffmpeg N-77008-g085ab74, ffprobe N-77008-g085ab74
[debug] Proxy map: {}
It looks like you installed youtube-dl with a package manager, pip, setup.py or
a tarball. Please use that to update.

working from directory:

C:\Users\Cos\Documents\Linux\bin>youtube-dl.exe -U -v
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'-U', u'-v']
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2015.11.27.1
[debug] Python version 2.7.10 - Windows-7-6.1.7601-SP1
[debug] exe versions: ffmpeg N-77008-g085ab74, ffprobe N-77008-g085ab74
[debug] Proxy map: {}
Updating to version 2015.12.23 ...
Waiting for file handle to be closed ...

C:\Users\Cos\Documents\Linux\bin>Updated youtube-dl to version 2015.12.23.
@AGSPhoenix
Copy link
Contributor

@AGSPhoenix AGSPhoenix commented Dec 25, 2015

Hmm. The behaviour of not being about to update without navigating to the directory the binary in is the same as with the other bug, but I have to wonder at what could be happening to cause that error.

@dstftw, I think this should be looked into. Could you consider reopening it?

@latot
Copy link
Author

@latot latot commented Dec 25, 2015

mm, only to be sure.
the other bug is the perms error? its feels very different, in that bug in fact affect the PATH, but the focus of the error are perms to write, here affects PATH too, but here its the recognition of the installation type (manual vs package manager)

@Hrxn
Copy link

@Hrxn Hrxn commented Dec 26, 2015

That is the known bug that was mentioned earlier, #2718

@AGSPhoenix
Copy link
Contributor

@AGSPhoenix AGSPhoenix commented Dec 27, 2015

@Hrxn, #2718 presents itself as a no write permissions error, like so:

C:\Users\Phoenix>where youtube-dl
C:\Users\Phoenix\bin\youtube-dl.exe

C:\Users\Phoenix>youtube-dl -U
Updating to version 2015.12.23 ...
ERROR: no write permissions on youtube-dl

This check happens in update.py at either line 108 or line 116 right below.

However, the message @latot is encountering is a result of the code at line 55, which seems to be failing to determine the installation type correctly. They don't seem related to me.

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.