From c6310eca9296d388e403e5ff444a0f193d59509d Mon Sep 17 00:00:00 2001 From: appolli Date: Sat, 24 Aug 2024 12:44:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E9=83=A8=E5=88=86=E6=B5=8B?= =?UTF-8?q?=E8=AF=95=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/YoutubeUtils.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/common/YoutubeUtils.py b/common/YoutubeUtils.py index 5a99aa6..c23890c 100644 --- a/common/YoutubeUtils.py +++ b/common/YoutubeUtils.py @@ -22,10 +22,10 @@ class YouTubeUtil: # AIzaSyDjPkCgDQ9Tv_xcChjY2E6GpJ6IzngnD5I # AIzaSyAxIycOdQYGB5kWhwe3B-kJAYRo7wOnp8o apiKeys = [ - # "AIzaSyARaW3mqO9szQiHgWZR4el0HWvdyheSHBc", - # "AIzaSyChPXesnVx6fweon_BckhR6UiJWvi5Ma4s" + "AIzaSyARaW3mqO9szQiHgWZR4el0HWvdyheSHBc", + "AIzaSyChPXesnVx6fweon_BckhR6UiJWvi5Ma4s" - "AIzaSyCTBSbq0YjyxTtjmNsnDyKAwHamlv_ST-s" + # "AIzaSyCTBSbq0YjyxTtjmNsnDyKAwHamlv_ST-s" # "AIzaSyAESnwtbTIBtU707iZowtQkmAo-qKuEOcY" @@ -38,12 +38,12 @@ class YouTubeUtil: # 获取youtube对象 def getYoutube(): # 本地测试使用代码 - proxy_info = httplib2.ProxyInfo( - proxy_type=httplib2.socks.PROXY_TYPE_HTTP, proxy_host="127.0.0.1", proxy_port=7890) - http = httplib2.Http(timeout=10, proxy_info=proxy_info, - disable_ssl_certificate_validation=False) - # http = httplib2.Http( - # timeout=10, disable_ssl_certificate_validation=False) + # proxy_info = httplib2.ProxyInfo( + # proxy_type=httplib2.socks.PROXY_TYPE_HTTP, proxy_host="127.0.0.1", proxy_port=7890) + # http = httplib2.Http(timeout=10, proxy_info=proxy_info, + # disable_ssl_certificate_validation=False) + http = httplib2.Http( + timeout=10, disable_ssl_certificate_validation=False) api_service_name = "youtube" api_version = "v3" # 获取apiKey