From 4a9d9f2373ceb1417f688db64cf2afe92ebb4912 Mon Sep 17 00:00:00 2001 From: boyska Date: Thu, 9 Mar 2017 23:52:33 +0100 Subject: [PATCH] skip already existing files --- bandcavall/download.py | 1 + 1 file changed, 1 insertion(+) diff --git a/bandcavall/download.py b/bandcavall/download.py index 255723e..d5fb4b9 100644 --- a/bandcavall/download.py +++ b/bandcavall/download.py @@ -22,6 +22,7 @@ def download_track(track, args): os.makedirs(join(args.download_base, fdir), exist_ok=True) if exists(fpath): log.info('file %s exists, skipping' % fpath) + return log.debug('download in ' + fpath) resp = requests.get(track['url'], stream=True) if not resp.ok: