Open jinhere opened 1 year ago
Thanks for your offer. I'd definitely add it to the same module. Depending on how similar the page structure and URL patterns are, it may be possible to modify the NaverIE
class or otherwise a new extractor class, perhaps derived from NaverIE
or NaverBaseIE
.
The existing extractor handles pages whose URLs contain a fragment like /v/{numeric_video_id}
. Then it uses "secret knowledge" to look that ID up using an API URL that returns JSON metadata for the ID.
The first problem page has this interesting chunk:
<div class="_VOD_PLAYER_WRAP"
data-video-index="0"
data-video-id="0021E0A5FD56A21AF775A26D7F39FD5EFBC1"
data-inkey="V1284101883929cd8aa8a81e760f310062bc742c134593abb80254509b668f9fc60b381e760f310062bc7"
data-cover-image-url="https://mimgnews.pstatic.net/image/052/2022/11/13/cover_cover_202211132227471923_t_20221113223902322.jpg"
data-cover-image-thumbnail-url="https://mimgnews.pstatic.net/image/052/2022/11/13/cover_cover_202211132227471923_t_20221113223902322.jpg?type=w647"
data-nvp-playable="true">
</div>
This data-video-id
doesn't seem to be the sort of ID at all. You'll probably have to track the web traffic using your browser development tools to see how the data-video-id
gets transformed into the media URL.
Checklist
Example URLs
Description
Hello, the website i want support is 'naver news' which has a video and news letters at a single page. I ran the command and it says it is unsupported url. So i thought it could be solved by adding new extractor, but I've found there is an extractor called naver.py that extracts video from 'naver tv'(the video player looked similar). So my question is: do i have to make a new extractor or add codes in naver.py? I might be asking obvious question but this is my first time reading&contributing to big project so i want to ask you before starting.