mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-08 20:25:19 +02:00
Fix YouTube transcript API: replace deprecated get_transcript with fetch method
This commit is contained in:
parent
8bbc8dba4e
commit
c08508c0c4
1 changed files with 2 additions and 1 deletions
|
|
@ -136,7 +136,8 @@ async def add_youtube_video_document(
|
|||
)
|
||||
|
||||
try:
|
||||
captions = YouTubeTranscriptApi.get_transcript(video_id)
|
||||
ytt_api = YouTubeTranscriptApi()
|
||||
captions = ytt_api.fetch(video_id)
|
||||
# Include complete caption information with timestamps
|
||||
transcript_segments = []
|
||||
for line in captions:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue