From f7a6d6c8d4b4a73d20241dc46bedb0e317d6f793 Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Sat, 11 Jul 2020 13:00:24 -0700 Subject: [PATCH] remove https:// prefix from curl commands fix #355 --- utils/google_utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/utils/google_utils.py b/utils/google_utils.py index 42b7b01..0a3dec1 100644 --- a/utils/google_utils.py +++ b/utils/google_utils.py @@ -46,12 +46,12 @@ def gdrive_download(id='1n_oKgR81BJtqk75b00eAjdv03qVCQn2f', name='coco128.zip'): os.remove('cookie') if os.path.exists('cookie') else None # Attempt file download - os.system("curl -c ./cookie -s -L \"https://drive.google.com/uc?export=download&id=%s\" > /dev/null" % id) + os.system("curl -c ./cookie -s -L \"drive.google.com/uc?export=download&id=%s\" > /dev/null" % id) if os.path.exists('cookie'): # large file - s = "curl -Lb ./cookie \"https://drive.google.com/uc?export=download&confirm=`awk '/download/ {print $NF}' ./cookie`&id=%s\" -o %s" % ( + s = "curl -Lb ./cookie \"drive.google.com/uc?export=download&confirm=`awk '/download/ {print $NF}' ./cookie`&id=%s\" -o %s" % ( id, name) else: # small file - s = "curl -s -L -o %s 'https://drive.google.com/uc?export=download&id=%s'" % (name, id) + s = "curl -s -L -o %s 'drive.google.com/uc?export=download&id=%s'" % (name, id) r = os.system(s) # execute, capture return values os.remove('cookie') if os.path.exists('cookie') else None