Skip to content

Commit

Permalink
[rai] Detect ContentItem in iframe (closes ytdl-org#12652) (ytdl-org#…
Browse files Browse the repository at this point in the history
…27673)

Co-authored-by: Sergey M. <[email protected]>
  • Loading branch information
2 people authored and ThirumalaiK committed Jan 28, 2021
1 parent 84d6bd5 commit 60ae369
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion youtube_dl/extractor/rai.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,19 @@ class RaiIE(RaiBaseIE):
'params': {
'skip_download': True,
},
}, {
# ContentItem in iframe (see #12652)
'url': 'http://www.presadiretta.rai.it/dl/portali/site/puntata/ContentItem-3ed19d13-26c2-46ff-a551-b10828262f1b.html',
'info_dict': {
'id': '1ad6dc64-444a-42a4-9bea-e5419ad2f5fd',
'ext': 'mp4',
'title': 'Partiti acchiappavoti - Presa diretta del 13/09/2015',
'description': 'md5:d291b03407ec505f95f27970c0b025f4',
'upload_date': '20150913',
},
'params': {
'skip_download': True,
},
}, {
# Direct MMS URL
'url': 'http://www.rai.it/dl/RaiTV/programmi/media/ContentItem-b63a4089-ac28-48cf-bca5-9f5b5bc46df5.html',
Expand Down Expand Up @@ -403,7 +416,8 @@ def _real_extract(self, url):
r'''(?x)
(?:
(?:initEdizione|drawMediaRaiTV)\(|
<(?:[^>]+\bdata-id|var\s+uniquename)=
<(?:[^>]+\bdata-id|var\s+uniquename)=|
<iframe[^>]+\bsrc=
)
(["\'])
(?:(?!\1).)*\bContentItem-(?P<id>%s)
Expand Down

0 comments on commit 60ae369

Please sign in to comment.