Better Post-Live Manifestless mode.
This commit is contained in:
parent
67d7f61a07
commit
3a5d2b93f5
1 changed files with 4 additions and 6 deletions
|
|
@ -156,6 +156,10 @@ class DownloadQueue:
|
||||||
if dlInfo.info.live_in:
|
if dlInfo.info.live_in:
|
||||||
dlInfo.info.status = 'not_live'
|
dlInfo.info.status = 'not_live'
|
||||||
itemDownload = self.done.put(dlInfo)
|
itemDownload = self.done.put(dlInfo)
|
||||||
|
elif self.config.allow_manifestless is False and 'live_status' in entry and 'post_live' == entry.get('live_status'):
|
||||||
|
dlInfo.info.status = 'error'
|
||||||
|
dlInfo.info.error = 'Video is in Post-Live Manifestless mode.'
|
||||||
|
itemDownload = self.done.put(dlInfo)
|
||||||
else:
|
else:
|
||||||
itemDownload = self.queue.put(dlInfo)
|
itemDownload = self.queue.put(dlInfo)
|
||||||
self.event.set()
|
self.event.set()
|
||||||
|
|
@ -221,18 +225,12 @@ class DownloadQueue:
|
||||||
if self.isDownloaded(entry):
|
if self.isDownloaded(entry):
|
||||||
raise yt_dlp.utils.ExistingVideoReached()
|
raise yt_dlp.utils.ExistingVideoReached()
|
||||||
|
|
||||||
if self.config.allow_manifestless is False and 'live_status' in entry and 'post_live' == entry.get('live_status'):
|
|
||||||
raise yt_dlp.utils.YoutubeDLError(
|
|
||||||
'Video is in Post-Live Manifestless mode.')
|
|
||||||
|
|
||||||
log.debug(f'entry: extract info says: {entry}')
|
log.debug(f'entry: extract info says: {entry}')
|
||||||
except yt_dlp.utils.ExistingVideoReached:
|
except yt_dlp.utils.ExistingVideoReached:
|
||||||
return {'status': 'error', 'msg': 'Video has been downloaded already and recorded in archive.log file.'}
|
return {'status': 'error', 'msg': 'Video has been downloaded already and recorded in archive.log file.'}
|
||||||
except yt_dlp.utils.YoutubeDLError as exc:
|
except yt_dlp.utils.YoutubeDLError as exc:
|
||||||
return {'status': 'error', 'msg': str(exc)}
|
return {'status': 'error', 'msg': str(exc)}
|
||||||
|
|
||||||
#
|
|
||||||
|
|
||||||
return await self.__add_entry(
|
return await self.__add_entry(
|
||||||
entry=entry,
|
entry=entry,
|
||||||
quality=quality,
|
quality=quality,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue