mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-12-26 05:05:54 +01:00
Fix typecasting when pre-checking archive (Closes #26)
This commit is contained in:
parent
610d8e7692
commit
d0757229fa
@ -885,7 +885,9 @@ def extract_info(self, url, download=True, ie_key=None, info_dict=None, extra_in
|
|||||||
'and will probably not work.')
|
'and will probably not work.')
|
||||||
|
|
||||||
try:
|
try:
|
||||||
temp_id = ie.extract_id(url) if callable(getattr(ie, 'extract_id', None)) else ie._match_id(url)
|
temp_id = str_or_none(
|
||||||
|
ie.extract_id(url) if callable(getattr(ie, 'extract_id', None))
|
||||||
|
else ie._match_id(url))
|
||||||
except (AssertionError, IndexError, AttributeError):
|
except (AssertionError, IndexError, AttributeError):
|
||||||
temp_id = None
|
temp_id = None
|
||||||
if temp_id is not None and self.in_download_archive({'id': temp_id, 'ie_key': ie_key}):
|
if temp_id is not None and self.in_download_archive({'id': temp_id, 'ie_key': ie_key}):
|
||||||
@ -2364,7 +2366,7 @@ def _make_archive_id(self, info_dict):
|
|||||||
break
|
break
|
||||||
else:
|
else:
|
||||||
return
|
return
|
||||||
return extractor.lower() + ' ' + video_id
|
return '%s %s' % (extractor.lower(), video_id)
|
||||||
|
|
||||||
def in_download_archive(self, info_dict):
|
def in_download_archive(self, info_dict):
|
||||||
fn = self.params.get('download_archive')
|
fn = self.params.get('download_archive')
|
||||||
|
Loading…
Reference in New Issue
Block a user