commit 739a0851dca6b072dc28c727a011c569ff1f0e48
parent 5c3c1ac00a4a2e426dcbbfc1f30f600f65dff408
Author: gearsix <gearsix@tuta.io>
Date: Sun, 4 Feb 2024 12:43:01 +0000
added utf-8 encode handling to tracklist parser
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/sya.py b/src/sya.py
@@ -53,7 +53,7 @@ def get_audio(youtubedl, url, outdir, format='mp3', quality='320K', keep=True, f
def load_tracklist(path):
tracklist = []
url = ''
- tracklist_file = open(path, mode = 'r')
+ tracklist_file = open(path, mode = 'r', encoding='utf-8', errors='ignore')
for i, t in enumerate(tracklist_file.readlines()):
t = t.strip('\n\t ')
if i == 0: