mirror of
https://github.com/glomatico/gamdl.git
synced 2026-06-13 12:15:18 +03:00
Refactor error handling to use GamdlError
This commit is contained in:
+2
-9
@@ -17,9 +17,7 @@ from ..downloader import (
|
||||
CoverFormat,
|
||||
DownloadItem,
|
||||
DownloadMode,
|
||||
FormatNotAvailable,
|
||||
NotStreamable,
|
||||
SyncedLyricsOnly,
|
||||
GamdlError,
|
||||
RemuxFormatMusicVideo,
|
||||
RemuxMode,
|
||||
)
|
||||
@@ -603,12 +601,7 @@ async def main(
|
||||
|
||||
try:
|
||||
await downloader.download(download_item)
|
||||
except (
|
||||
FileExistsError,
|
||||
NotStreamable,
|
||||
FormatNotAvailable,
|
||||
SyncedLyricsOnly,
|
||||
) as e:
|
||||
except GamdlError as e:
|
||||
logger.warning(
|
||||
download_queue_progress + f' Skipping "{media_title}": {e}'
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user