radio_util: open tracks SQLite DB in readonly mode; black: reformat files
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
from dataclasses import dataclass
|
||||
from typing import Union
|
||||
|
||||
|
||||
@dataclass
|
||||
class LyricsResult:
|
||||
"""
|
||||
@ -12,31 +13,37 @@ class LyricsResult:
|
||||
lyrics (Union[str, list]): str if plain lyrics, list for lrc
|
||||
time (float): time taken to retrieve lyrics from source
|
||||
"""
|
||||
|
||||
artist: str
|
||||
song: str
|
||||
src: str
|
||||
lyrics: Union[str, list]
|
||||
confidence: int
|
||||
time: float = 0.00
|
||||
|
||||
|
||||
|
||||
"""
|
||||
Generic
|
||||
"""
|
||||
|
||||
|
||||
class InvalidLyricSearchResponseException(Exception):
|
||||
pass
|
||||
|
||||
|
||||
"""
|
||||
Genius
|
||||
"""
|
||||
class InvalidGeniusResponseException(
|
||||
InvalidLyricSearchResponseException):
|
||||
|
||||
|
||||
class InvalidGeniusResponseException(InvalidLyricSearchResponseException):
|
||||
pass
|
||||
|
||||
|
||||
"""
|
||||
LRCLib
|
||||
"""
|
||||
|
||||
class InvalidLRCLibResponseException(
|
||||
InvalidLyricSearchResponseException):
|
||||
pass
|
||||
|
||||
class InvalidLRCLibResponseException(InvalidLyricSearchResponseException):
|
||||
pass
|
||||
|
Reference in New Issue
Block a user