You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
mobj=re.search(r'(?s)Provided to YouTube by [^\n]+\n+(?P<track>[^·]+)·(?P<artist>[^\n]+)\n+(?P<album>[^\n]+)(?:.+?℗\s*(?P<release_year>\d{4})(?!\d))?(?:.+?Released on\s*:\s*(?P<release_date>\d{4}-\d{2}-\d{2}))?(.+?\nArtist\s*:\s*(?P<clean_artist>[^\n]+))?', video_description)
It doesn't match because the first expected line in the regex Provided to YouTube by ... is not present in this example.
See this: https://regex101.com/r/ymfTr6/1
To fix this, maybe we can rely on the last line of the descriptions being Auto-generated by YouTube..
Checklist
Verbose log
Description
I am on the current master which is a115e07.
This regex is used to extract the artist and title of a Youtube Music video.
youtube-dl/youtube_dl/extractor/youtube.py
Line 2329 in a115e07
It doesn't match because the first expected line in the regex
Provided to YouTube by ...
is not present in this example.See this: https://regex101.com/r/ymfTr6/1
To fix this, maybe we can rely on the last line of the descriptions being
Auto-generated by YouTube.
.Here are more examples:
And here is a video which is currently correctly detected: https://www.youtube.com/watch?v=UoGWcFCf-sE
The text was updated successfully, but these errors were encountered: