Fix: [2.0.11] 라이브 DownloadError 스킵 처리 및 채널명 표시
All checks were successful
news-summary-bot-cicd / build_push_deploy (push) Successful in 12m11s
All checks were successful
news-summary-bot-cicd / build_push_deploy (push) Successful in 12m11s
- yt-dlp DownloadError에서 라이브/프리미어 감지 시 SkipVideo로 변환 (500 방지) - channel_name 필드 추가로 Discord 알림에 채널명(머니코믹스/슈카월드) 표시 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -42,6 +42,11 @@ def fetch_transcript(video_id: str) -> str:
|
||||
try:
|
||||
with yt_dlp.YoutubeDL(ydl_opts) as ydl:
|
||||
info = ydl.extract_info(url, ie_key="Youtube", download=False, process=False)
|
||||
except yt_dlp.utils.DownloadError as e:
|
||||
err_msg = str(e).lower()
|
||||
if "live event" in err_msg or "is live" in err_msg or "premieres in" in err_msg:
|
||||
raise SkipVideo("라이브/예정 영상은 요약 대상이 아닙니다")
|
||||
raise
|
||||
finally:
|
||||
if "cookiefile" in ydl_opts:
|
||||
os.unlink(ydl_opts["cookiefile"])
|
||||
|
||||
Reference in New Issue
Block a user