From 005d17ee0ac648fd7979848494552db83a0525d9 Mon Sep 17 00:00:00 2001 From: Keith Edmunds Date: Sun, 19 Nov 2023 11:44:43 +0000 Subject: [PATCH] Check for no title/artist tag in replace_files --- app/replace_files.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/app/replace_files.py b/app/replace_files.py index d645f71..e8e9872 100755 --- a/app/replace_files.py +++ b/app/replace_files.py @@ -75,7 +75,13 @@ def main(): continue new_tags = get_tags(new_path) new_title = new_tags["title"] + if not new_title: + print(f"{new_fname} does not have a title tag") + sys.exit(1) new_artist = new_tags["artist"] + if not new_artist: + print(f"{new_fname} does not have an artist tag") + sys.exit(1) bitrate = new_tags["bitrate"] # If same filename exists in parent direcory, check tags