This commit is contained in:
2025-02-15 21:09:33 -05:00
parent 60416c493f
commit 39d1ddaffa
22 changed files with 509 additions and 525 deletions

View File

@ -1,5 +1,4 @@
#!/usr/bin/env python3.12
# pylint: disable=wrong-import-order, wrong-import-position
from typing import Optional
from lyric_search.constructors import LyricsResult
@ -22,7 +21,8 @@ class Aggregate:
self.redis_cache = redis_cache.RedisCache()
self.notifier = notifier.DiscordNotifier()
async def search(self, artist: str, song: str, plain: bool = True) -> Optional[LyricsResult]:
async def search(self, artist: str, song: str,
plain: Optional[bool] = True) -> Optional[LyricsResult]:
"""
Aggregate Search
Args:
@ -30,7 +30,7 @@ class Aggregate:
song (str): Song to search
plain (bool): Search for plain lyrics (lrc otherwise)
Returns:
LyricsResult|None: The result, if found - None otherwise.
Optional[LyricsResult]: The result, if found - None otherwise.
"""
if not plain:
logging.info("LRCs requested, limiting search to LRCLib")