aboutsummaryrefslogtreecommitdiffstats
path: root/youtube/watch.py
diff options
context:
space:
mode:
authorJames Taylor <user234683@users.noreply.github.com>2018-08-31 16:23:19 -0700
committerJames Taylor <user234683@users.noreply.github.com>2018-08-31 16:23:19 -0700
commitebfe58e6cbc866c5e2dc4876a6b5868837d504b3 (patch)
tree3de4d65fd73349963a1aca6a9e410fde23ded8c2 /youtube/watch.py
parent6980d93107354a8c075030a7bda4c3870449163b (diff)
downloadyt-local-ebfe58e6cbc866c5e2dc4876a6b5868837d504b3.tar.lz
yt-local-ebfe58e6cbc866c5e2dc4876a6b5868837d504b3.tar.xz
yt-local-ebfe58e6cbc866c5e2dc4876a6b5868837d504b3.zip
Ability to reply to comments
Diffstat (limited to 'youtube/watch.py')
-rw-r--r--youtube/watch.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/youtube/watch.py b/youtube/watch.py
index ad3c448..ff7d6df 100644
--- a/youtube/watch.py
+++ b/youtube/watch.py
@@ -385,6 +385,10 @@ def get_watch_page(query_string):
music_list_html += '''</tr>\n'''
music_list_html += '''</table>\n'''
+ with open('data/googlevideo-domains.txt', 'a+', encoding='utf-8') as f:
+ url = info['formats'][0]['url']
+ subdomain = url[0:url.find(".googlevideo.com")]
+ f.write(subdomain + "\n")
download_options = ''
for format in info['formats']: