feat: renamed artwork
This commit is contained in:
@@ -1,46 +1,33 @@
|
||||
from __future__ import unicode_literals, annotations
|
||||
from __future__ import annotations, unicode_literals
|
||||
|
||||
from typing import Dict, List, Optional, Set, Type
|
||||
from urllib.parse import urlparse, urlunparse, quote, parse_qs, urlencode
|
||||
import json
|
||||
import logging
|
||||
import random
|
||||
import json
|
||||
from dataclasses import dataclass
|
||||
import re
|
||||
from functools import lru_cache
|
||||
from collections import defaultdict
|
||||
from dataclasses import dataclass
|
||||
from functools import lru_cache
|
||||
from typing import Dict, List, Optional, Set, Type
|
||||
from urllib.parse import parse_qs, quote, urlencode, urlparse, urlunparse
|
||||
|
||||
import youtube_dl
|
||||
from youtube_dl.extractor.youtube import YoutubeIE
|
||||
from youtube_dl.utils import DownloadError
|
||||
|
||||
from ...connection import Connection
|
||||
from ...objects import Album, Artist, ArtworkCollection
|
||||
from ...objects import DatabaseObject as DataObject
|
||||
from ...objects import (FormattedText, ID3Timestamp, Label, Lyrics, Song,
|
||||
Source, Target)
|
||||
from ...utils import dump_to_file, get_current_millis, traverse_json_path
|
||||
from ...utils.config import logging_settings, main_settings, youtube_settings
|
||||
from ...utils.enums import ALL_SOURCE_TYPES, SourceType
|
||||
from ...utils.enums.album import AlbumType
|
||||
from ...utils.exception.config import SettingValueError
|
||||
from ...utils.config import main_settings, youtube_settings, logging_settings
|
||||
from ...utils.shared import DEBUG, DEBUG_YOUTUBE_INITIALIZING
|
||||
from ...utils.string_processing import clean_song_title
|
||||
from ...utils import get_current_millis, traverse_json_path
|
||||
|
||||
from ...utils import dump_to_file
|
||||
|
||||
from ..abstract import Page
|
||||
from ...objects import (
|
||||
DatabaseObject as DataObject,
|
||||
Source,
|
||||
FormattedText,
|
||||
ID3Timestamp,
|
||||
Artwork,
|
||||
Artist,
|
||||
Song,
|
||||
Album,
|
||||
Label,
|
||||
Target,
|
||||
Lyrics,
|
||||
)
|
||||
from ...connection import Connection
|
||||
from ...utils.enums import SourceType, ALL_SOURCE_TYPES
|
||||
from ...utils.enums.album import AlbumType
|
||||
from ...utils.support_classes.download_result import DownloadResult
|
||||
|
||||
from ..abstract import Page
|
||||
from ._list_render import parse_renderer
|
||||
from ._music_object_render import parse_run_element
|
||||
from .super_youtube import SuperYouTube
|
||||
@@ -646,7 +633,7 @@ class YoutubeMusic(SuperYouTube):
|
||||
note=ydl_res.get("descriptions"),
|
||||
album_list=album_list,
|
||||
length=int(ydl_res.get("duration", 0)) * 1000,
|
||||
artwork=Artwork(*ydl_res.get("thumbnails", [])),
|
||||
artwork=ArtworkCollection(*ydl_res.get("thumbnails", [])),
|
||||
artist_list=artist_list,
|
||||
source_list=[Source(
|
||||
self.SOURCE_TYPE,
|
||||
|
||||
Reference in New Issue
Block a user