diff options
author | 吳俊翰 | 2023-05-08 15:33:25 +0800 |
---|---|---|
committer | GitHub | 2023-05-08 15:33:25 +0800 |
commit | 2146f5fb8ed94ba5edf4859261ec9ba241ee43a9 (patch) | |
tree | 5eafe8edb7b8020379f1ff1ecdd9efcad13acc27 /main.py | |
parent | 33f0a57e75473f020b263fc5616ae426f1c97a38 (diff) |
Update main.py
Diffstat (limited to 'main.py')
-rw-r--r-- | main.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -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 |