o
    i	                     @   sD   d dl mZ ddlmZmZmZ ddlmZmZ G dd deZ	dS )   )InfoExtractor   )ExtractorError
clean_htmlurl_or_none)subs_list_to_dicttraverse_objc                
   @   s^   e Zd ZdZdZdZdZdddddd	gd
ddddddddd	dgddddgZdd ZdS )MonsterSirenHypergryphMusicIEmonstersirenu   塞壬唱片z(https://monster-siren.hypergryph.com/apiz9https?://monster-siren\.hypergryph\.com/music/(?P<id>\d+)z1https://monster-siren.hypergryph.com/music/514562514562wavzFlame Shadowu   塞壬唱片-MSRz$md5:19e2acfcd1b65b41b29e8079ab948053z,re:https?://web\.hycdn\.cn/siren/pic/.+\.jpg)idexttitlealbumartistsdescription	thumbnail)url	info_dictz1https://monster-siren.hypergryph.com/music/514518514518zHeavenly Me (Instrumental)zHeavenly Meu   AIYUE blessed : 理名z$md5:ce790b41c932d1ad72eb791d1d8ae598c                 C   s   |  |}| | j d| |}t|ddkr+t|dthtf}t|p%dt|dd }t|ddthf }rG| j| j d	| d
|dd}|ddt|ddthfddthfdditt	ddhfdt
hfdft|ddthfdthfdt
hfdfS )Nz/song/code    msgzAPI returned an error response)expecteddataalbumCidz/album/z/detailF)fatalnone)r   vcodecnamer   .r   lyricUrlen)lang	sourceUrl)r   r   	subtitlesr   introcoverUrl)r   r   r   )	_match_id_download_json	_API_BASEr   strfilterr   boolallr   r   r   )selfr   audio_idsongr   r   album_id r3   O/home/ubuntu/.local/lib/python3.10/site-packages/yt_dlp/extractor/hypergryph.py_real_extract'   s8   

	z+MonsterSirenHypergryphMusicIE._real_extractN)	__name__
__module____qualname__IE_NAMEIE_DESCr*   
_VALID_URL_TESTSr5   r3   r3   r3   r4   r	   
   s6    r	   N)
commonr   utilsr   r   r   utils.traversalr   r   r	   r3   r3   r3   r4   <module>   s    