adjusted to changes in YouTube webclient
This commit is contained in:
parent
ee4741d77a
commit
5d0e407f89
|
@ -28,7 +28,9 @@ class YouTubeTranscriptApi():
|
||||||
' - none of the languages you provided are supported by the video\n'
|
' - none of the languages you provided are supported by the video\n'
|
||||||
' - the video is no longer available.\n\n'
|
' - the video is no longer available.\n\n'
|
||||||
'If none of these things is the case, please create an issue at '
|
'If none of these things is the case, please create an issue at '
|
||||||
'https://github.com/jdepoix/youtube-transcript-api/issues'
|
'https://github.com/jdepoix/youtube-transcript-api/issues.'
|
||||||
|
'Please add which version of youtube_transcript_api you are using and make sure that there '
|
||||||
|
'are no open issues which already describe your problem!'
|
||||||
)
|
)
|
||||||
|
|
||||||
def __init__(self, video_id):
|
def __init__(self, video_id):
|
||||||
|
@ -99,7 +101,7 @@ class _TranscriptFetcher():
|
||||||
WATCH_URL = 'https://www.youtube.com/watch?v={video_id}'
|
WATCH_URL = 'https://www.youtube.com/watch?v={video_id}'
|
||||||
API_BASE_URL = 'https://www.youtube.com/api/{api_url}'
|
API_BASE_URL = 'https://www.youtube.com/api/{api_url}'
|
||||||
LANGUAGE_REGEX = re.compile(r'(&lang=.*&)|(&lang=.*)')
|
LANGUAGE_REGEX = re.compile(r'(&lang=.*&)|(&lang=.*)')
|
||||||
TIMEDTEXT_STRING = 'timedtext'
|
TIMEDTEXT_STRING = 'timedtext?v='
|
||||||
|
|
||||||
def __init__(self, video_id, languages, proxies):
|
def __init__(self, video_id, languages, proxies):
|
||||||
self.video_id = video_id
|
self.video_id = video_id
|
||||||
|
|
Loading…
Reference in New Issue