{"action":"created","issue":{"url":"https://api.github.com/repos/rg3/youtube-dl/issues/14353","repository_url":"https://api.github.com/repos/rg3/youtube-dl","labels_url":"https://api.github.com/repos/rg3/youtube-dl/issues/14353/labels{/name}","comments_url":"https://api.github.com/repos/rg3/youtube-dl/issues/14353/comments","events_url":"https://api.github.com/repos/rg3/youtube-dl/issues/14353/events","html_url":"https://github.com/rg3/youtube-dl/pull/14353","id":261256405,"number":14353,"title":"Instructions to resolve TLS v1.0 error on macOS","user":{"login":"dmlemos","id":1868454,"avatar_url":"https://avatars0.githubusercontent.com/u/1868454?v=4","gravatar_id":"","url":"https://api.github.com/users/dmlemos","html_url":"https://github.com/dmlemos","followers_url":"https://api.github.com/users/dmlemos/followers","following_url":"https://api.github.com/users/dmlemos/following{/other_user}","gists_url":"https://api.github.com/users/dmlemos/gists{/gist_id}","starred_url":"https://api.github.com/users/dmlemos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmlemos/subscriptions","organizations_url":"https://api.github.com/users/dmlemos/orgs","repos_url":"https://api.github.com/users/dmlemos/repos","events_url":"https://api.github.com/users/dmlemos/events{/privacy}","received_events_url":"https://api.github.com/users/dmlemos/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2017-09-28T09:44:23Z","updated_at":"2018-05-27T18:01:48Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/rg3/youtube-dl/pulls/14353","html_url":"https://github.com/rg3/youtube-dl/pull/14353","diff_url":"https://github.com/rg3/youtube-dl/pull/14353.diff","patch_url":"https://github.com/rg3/youtube-dl/pull/14353.patch"},"body":"### Before submitting a *pull request* make sure you have:\r\n- [x] At least skimmed through [adding new extractor tutorial](https://github.com/rg3/youtube-dl#adding-support-for-a-new-site) and [youtube-dl coding conventions](https://github.com/rg3/youtube-dl#youtube-dl-coding-conventions) sections\r\n- [x] [Searched](https://github.com/rg3/youtube-dl/search?q=is%3Apr&type=Issues) the bugtracker for similar pull requests\r\n\r\n### In order to be accepted and merged into youtube-dl each piece of code must be in public domain or released under [Unlicense](http://unlicense.org/). Check one of the following options:\r\n- [x] I am the original author of this code and I am willing to release it under [Unlicense](http://unlicense.org/)\r\n\r\n### What is the purpose of your *pull request*?\r\n- [ ] Bug fix\r\n- [X] Improvement\r\n- [ ] New extractor\r\n- [ ] New feature\r\n\r\n---\r\n\r\n### Description of your *pull request* and other information\r\n\r\nBefore I was using system python and noticed `youtube-dl` was complaining about the TLS protocol version on certain websites:\r\n\r\n```sh\r\n$ youtube-dl --verbose https://cauchemar.bandcamp.com/album/chapelle-ardente\r\n[debug] System config: []\r\n[debug] User config: []\r\n[debug] Custom config: []\r\n[debug] Command-line args: [u'--verbose', u'https://cauchemar.bandcamp.com/album/chapelle-ardente']\r\n[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8\r\n[debug] youtube-dl version 2017.09.24\r\n[debug] Python version 2.7.10 - Darwin-16.7.0-x86_64-i386-64bit\r\n[debug] exe versions: ffmpeg 3.3.4, ffprobe 3.3.4\r\n[debug] Proxy map: {}\r\n[Bandcamp:album] chapelle-ardente: Downloading webpage\r\n[download] Downloading playlist: Chapelle ardente\r\n[Bandcamp:album] playlist Chapelle ardente: Collected 9 video ids (downloading 9 of them)\r\n[download] Downloading video 1 of 9\r\n[Bandcamp] n-cromancie: Downloading webpage\r\n[debug] Default format spec: bestvideo+bestaudio/best\r\n[debug] Invoking downloader on u'https://t4.bcbits.com/stream/f2cd5386df394ca9ea7356be56707148/mp3-128/4099989480?p=0&ts=1506596271&t=ac53a5efdcce9856b2a44e28bc8c6074948da14d&token=1506596271_d948460a3fb21d71fd4965a2f0f07affe97fa509'\r\nERROR: unable to download video data: <urlopen error [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:590)>\r\nTraceback (most recent call last):\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py\", line 1875, in process_info\r\n    success = dl(filename, info_dict)\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py\", line 1814, in dl\r\n    return fd.download(name, info)\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py\", line 361, in download\r\n    return self.real_download(filename, info_dict)\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/downloader/http.py\", line 286, in real_download\r\n    establish_connection()\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/downloader/http.py\", line 74, in establish_connection\r\n    ctx.data = self.ydl.urlopen(request)\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py\", line 2178, in urlopen\r\n    return self._opener.open(req, timeout=self._socket_timeout)\r\n  File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py\", line 431, in open\r\n    response = self._open(req, data)\r\n  File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py\", line 449, in _open\r\n    '_open', req)\r\n  File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py\", line 409, in _call_chain\r\n    result = func(*args)\r\n  File \"/usr/local/bin/youtube-dl/youtube_dl/utils.py\", line 1086, in https_open\r\n    req, **kwargs)\r\n  File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py\", line 1197, in do_open\r\n    raise URLError(err)\r\nURLError: <urlopen error [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:590)>\r\n```\r\n\r\nUpon investigating, python was using an older openssl version:\r\n```sh\r\n$ python -c 'import ssl; print(ssl.OPENSSL_VERSION)'\r\nOpenSSL 0.9.8zh 14 Jan 2016\r\n```\r\n\r\nThis pull request provides instructions on how to fix this error on macOS.\r\n\r\nShould help with these issues #13936 #12976"},"comment":{"url":"https://api.github.com/repos/rg3/youtube-dl/issues/comments/392351299","html_url":"https://github.com/rg3/youtube-dl/pull/14353#issuecomment-392351299","issue_url":"https://api.github.com/repos/rg3/youtube-dl/issues/14353","id":392351299,"user":{"login":"Wowfunhappy","id":4484096,"avatar_url":"https://avatars1.githubusercontent.com/u/4484096?v=4","gravatar_id":"","url":"https://api.github.com/users/Wowfunhappy","html_url":"https://github.com/Wowfunhappy","followers_url":"https://api.github.com/users/Wowfunhappy/followers","following_url":"https://api.github.com/users/Wowfunhappy/following{/other_user}","gists_url":"https://api.github.com/users/Wowfunhappy/gists{/gist_id}","starred_url":"https://api.github.com/users/Wowfunhappy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Wowfunhappy/subscriptions","organizations_url":"https://api.github.com/users/Wowfunhappy/orgs","repos_url":"https://api.github.com/users/Wowfunhappy/repos","events_url":"https://api.github.com/users/Wowfunhappy/events{/privacy}","received_events_url":"https://api.github.com/users/Wowfunhappy/received_events","type":"User","site_admin":false},"created_at":"2018-05-27T18:01:48Z","updated_at":"2018-05-27T18:01:48Z","author_association":"NONE","body":"What I've been doing, everywhere I used to do youtube-dl --update, I instead do:\r\n\r\ncurl -L http://yt-dl.org/downloads/latest/youtube-dl -o /usr/local/bin/youtube-dl\r\nchmod a+rx /usr/local/bin/youtube-dl\r\n\r\nThis a huge disadvantage in that a new copy will be downloaded regardless of whether or not there's an update available, but what can you do?"}}
{"actor":{"display_login":"Wowfunhappy"}}