Fix description
This commit is contained in:
@@ -226,8 +226,7 @@ class LiveChatAsync:
|
|||||||
if contents is None or self._is_replay:
|
if contents is None or self._is_replay:
|
||||||
'''Try to fetch archive chat data.'''
|
'''Try to fetch archive chat data.'''
|
||||||
self._parser.is_replay = True
|
self._parser.is_replay = True
|
||||||
self._fetch_url = ("live_chat_replay/"
|
self._fetch_url = "live_chat_replay/get_live_chat_replay?continuation="
|
||||||
"get_live_chat_replay?continuation=")
|
|
||||||
continuation = arcparam.getparam(
|
continuation = arcparam.getparam(
|
||||||
self.video_id, self.seektime, self._topchat_only)
|
self.video_id, self.seektime, self._topchat_only)
|
||||||
livechat_json = (await self._get_livechat_json(
|
livechat_json = (await self._get_livechat_json(
|
||||||
|
|||||||
@@ -104,7 +104,7 @@ class LiveChat:
|
|||||||
self._pauser.put_nowait(None)
|
self._pauser.put_nowait(None)
|
||||||
self._setup()
|
self._setup()
|
||||||
self._first_fetch = True
|
self._first_fetch = True
|
||||||
self._fetch_url = "live_chat/get_live_chat?continuation=",
|
self._fetch_url = "live_chat/get_live_chat?continuation="
|
||||||
self._topchat_only = topchat_only
|
self._topchat_only = topchat_only
|
||||||
if not LiveChat._setup_finished:
|
if not LiveChat._setup_finished:
|
||||||
LiveChat._setup_finished = True
|
LiveChat._setup_finished = True
|
||||||
@@ -218,8 +218,7 @@ class LiveChat:
|
|||||||
if contents is None or self._is_replay:
|
if contents is None or self._is_replay:
|
||||||
'''Try to fetch archive chat data.'''
|
'''Try to fetch archive chat data.'''
|
||||||
self._parser.is_replay = True
|
self._parser.is_replay = True
|
||||||
self._fetch_url = ("live_chat_replay/"
|
self._fetch_url = "live_chat_replay/get_live_chat_replay?continuation="
|
||||||
"get_live_chat_replay?continuation=")
|
|
||||||
continuation = arcparam.getparam(self.video_id, self.seektime)
|
continuation = arcparam.getparam(self.video_id, self.seektime)
|
||||||
livechat_json = ( self._get_livechat_json(
|
livechat_json = ( self._get_livechat_json(
|
||||||
continuation, session, headers))
|
continuation, session, headers))
|
||||||
@@ -234,8 +233,7 @@ class LiveChat:
|
|||||||
continuation = urllib.parse.quote(continuation)
|
continuation = urllib.parse.quote(continuation)
|
||||||
livechat_json = None
|
livechat_json = None
|
||||||
status_code = 0
|
status_code = 0
|
||||||
url =(
|
url =f"https://www.youtube.com/{self._fetch_url}{continuation}&pbj=1"
|
||||||
f"https://www.youtube.com/{self._fetch_url}{continuation}&pbj=1")
|
|
||||||
for _ in range(MAX_RETRY + 1):
|
for _ in range(MAX_RETRY + 1):
|
||||||
with session.get(url ,headers = headers) as resp:
|
with session.get(url ,headers = headers) as resp:
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user