Skip to content

Commit

Permalink
Fixing YouTube to not verify SSL certs.
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelclay committed Mar 9, 2018
1 parent 9a2545b commit 364ff9d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/feed_fetcher.py
Expand Up @@ -225,7 +225,7 @@ def fetch_youtube(self, address):
return

if channel_id:
video_ids_xml = requests.get("https://www.youtube.com/feeds/videos.xml?channel_id=%s" % channel_id)
video_ids_xml = requests.get("https://www.youtube.com/feeds/videos.xml?channel_id=%s" % channel_id, verify=False)
channel_json = requests.get("https://www.googleapis.com/youtube/v3/channels?part=snippet&id=%s&key=%s" %
(channel_id, settings.YOUTUBE_API_KEY))
channel = json.decode(channel_json.content)
Expand All @@ -245,7 +245,7 @@ def fetch_youtube(self, address):
return
channel_url = "https://www.youtube.com/playlist?list=%s" % list_id
elif username:
video_ids_xml = requests.get("https://www.youtube.com/feeds/videos.xml?user=%s" % username)
video_ids_xml = requests.get("https://www.youtube.com/feeds/videos.xml?user=%s" % username, verify=False)
description = "YouTube videos uploaded by %s" % username
else:
return
Expand Down

0 comments on commit 364ff9d

Please sign in to comment.