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

Will not update on OSX High Sierra #15474

Closed
Slowly opened this issue Feb 2, 2018 · 8 comments
Closed

Will not update on OSX High Sierra #15474

Slowly opened this issue Feb 2, 2018 · 8 comments

Comments

@Slowly
Copy link

@Slowly Slowly commented Feb 2, 2018

Make sure you are using the latest version: run youtube-dl --version and ensure your version is 2018.01.27. If it's not, read this FAQ entry and update. Issues with outdated version will be rejected.

  • I've verified and I assure that I'm running youtube-dl 2018.01.27

######################################################################

BashPrompt>youtube-dl -v -U

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'-v', u'-U']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2018.01.21
[debug] Python version 2.7.13 (CPython) - Darwin-17.4.0-x86_64-i386-64bit
[debug] exe versions: ffmpeg 3.4.1, ffprobe 3.4.1, rtmpdump 2.4
[debug] Proxy map: {}
Traceback (most recent call last):
File "/Users/Pudnik/bin/youtube-dl/youtube_dl/update.py", line 45, in update_self
newversion = opener.open(VERSION_URL).read().decode('utf-8').strip()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 429, in open
response = self._open(req, data)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 447, in _open
'_open', req)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 407, in _call_chain
result = func(*args)
File "/Users/Pudnik/bin/youtube-dl/youtube_dl/utils.py", line 1089, in https_open
req, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 1198, in do_open
raise URLError(err)
URLError: <urlopen error [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:661)>

ERROR: can't find the current version. Please try again later.

########################################################################

What is the purpose of your issue?

  • [X ] Bug report (encountered problems with youtube-dl)
  • Site support request (request for adding support for a new site)
  • Feature request (request for a new functionality)
  • Question
  • Other

If the purpose of this issue is a bug report, site support request or you are not completely sure provide the full verbose output as follows:

Add the -v flag to your command line you run youtube-dl with (youtube-dl -v <your command line>), copy the whole output and insert it here. It should look similar to one below (replace it with your log inserted between triple ```):

Description of your issue, suggested solution and other information

youtube-dl for OSX throws update error on OSX:

BashPrompt>youtube-dl -v -U

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'-v', u'-U']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2018.01.21
[debug] Python version 2.7.13 (CPython) - Darwin-17.4.0-x86_64-i386-64bit
[debug] exe versions: ffmpeg 3.4.1, ffprobe 3.4.1, rtmpdump 2.4
[debug] Proxy map: {}
Traceback (most recent call last):
File "/Users/Pudnik/bin/youtube-dl/youtube_dl/update.py", line 45, in update_self
newversion = opener.open(VERSION_URL).read().decode('utf-8').strip()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 429, in open
response = self._open(req, data)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 447, in _open
'_open', req)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 407, in _call_chain
result = func(*args)
File "/Users/Pudnik/bin/youtube-dl/youtube_dl/utils.py", line 1089, in https_open
req, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 1198, in do_open
raise URLError(err)
URLError: <urlopen error [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:661)>

ERROR: can't find the current version. Please try again later.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Feb 2, 2018

Most likely #14353.

@dstftw dstftw closed this Feb 2, 2018
@johnhawkinson
Copy link
Contributor

@johnhawkinson johnhawkinson commented Feb 3, 2018

I think a lot of people are going to have trouble finding the workaround instructions.
(I also wonder whether the advice to put the homebrew python in the users' PATH ahead of the system python is wise).

Unfortunately I don't have any good ideas on how to address this all. Other than if the error message had printed the updater URL, it would have been a place to offer guidance… But this precise situation seems unlikely to recur in the future? Maybe?

@cousteaulecommandant
Copy link

@cousteaulecommandant cousteaulecommandant commented Feb 4, 2018

Is falling back to http if https fails an option? (maybe after prompting the user)

@johnhawkinson
Copy link
Contributor

@johnhawkinson johnhawkinson commented Feb 4, 2018

Well, no existing user is going to see any fixes to this problem because the updater doesn't work, so even if that were acceptable...maybe instead give a link to a "What to do if the update fails?" page?

Although I suppose that Apple will probably push an update for openssl as more things in the OS break, and then this will work again…until the next time?

I guess it's worth addressing for people who are newly installing youtube-dl though?

@cousteaulecommandant
Copy link

@cousteaulecommandant cousteaulecommandant commented Feb 5, 2018

I don't think this is due to a recent bug on Apple; in fact I encountered this bug on a Linux machine I haven't upgraded in years (mea culpa), so this may be due to a change in github.io SSL protocols (this might be related to https://github.com/blog/2498-weak-cryptographic-standards-removal-notice). I guess eventually all machines that are regularly updated will find a fix for this SSL issue, but if Apple hasn't fixed this yet, I don't think it will do so soon.

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Feb 5, 2018

@Slowly How did you install Python on your machine?

@johnhawkinson
Copy link
Contributor

@johnhawkinson johnhawkinson commented Feb 5, 2018

How did you install Python on your machine?

I know you didn't ask me, but I saw this problem under MacOS 10.10 (Yosemite), which is somewhat long in the tooth. With the system Python, i.e. no special installation. For me:

[debug] Python version 2.7.10 (CPython) - Darwin-14.5.0-x86_64-i386-64bit

(And yes, installing a newer version of Python2 and putting it ahead in the PATH does "solve" the problem.)

@Slowly
Copy link
Author

@Slowly Slowly commented Feb 6, 2018

Here's how I think I'm going to fix it for me, using MacPorts. IMO, if you don't understand the terminal commands below...you don't belong on github. Github is for the tech savvy only. Go to videohelp.

which openssl
/opt/local/bin/openssl
|
|
v
sudo port selfupdate
sudo port upgrade outdated

---- OR -----

which openssl
sudo port selfupdate
sudo port upgrade outdated
sudo port install openssl

I have both python2 and python3 installed on my machine, and the environment variables are configured correctly. I have updated youtube-dl in both environments, and it works great.

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
5 participants
You can’t perform that action at this time.