aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author吳俊翰2023-05-08 15:33:25 +0800
committerGitHub2023-05-08 15:33:25 +0800
commit2146f5fb8ed94ba5edf4859261ec9ba241ee43a9 (patch)
tree5eafe8edb7b8020379f1ff1ecdd9efcad13acc27
parent33f0a57e75473f020b263fc5616ae426f1c97a38 (diff)
Update main.py
-rw-r--r--main.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.py b/main.py
index b73b728..f36ee27 100644
--- a/main.py
+++ b/main.py
@@ -142,14 +142,14 @@ def download_song(session, directory, name, url, song_counter, lock,file_format)
raise e
else:
retry_count += 1
- tqdm.write(f"Download of [{name}] failed. Retrying in 3 seconds ({retry_count}/{retries})", file=sys.stderr)
+ tqdm.write(f"Download of [{name}] failed. Retrying in 3 seconds ({retry_count}/{retries})")
time.sleep(3)
source = session.get(url, stream=True, timeout=timeout)
total = int(source.headers.get('content-length', 0))
downloaded = f.tell()
if downloaded < total:
- tqdm.write(f'Download of [{name}] was incomplete. Retrying...', file=sys.stderr)
+ tqdm.write(f'Download of [{name}] was incomplete. Retrying...')
os.remove(filename)
# Increase song counter