@@ -155,7 +155,7 @@ def upload_blob_s3(
155155 in the backend.
156156 """
157157 params = {"storageInterface" : "s3" , "objectName" : object_name }
158- presigned_json = self .get_request (endpoint , params = params )
158+ presigned_json = self .get_request (f" { endpoint } /presigned-url" , params = params )
159159 with open (file_path , "rb" ) as f :
160160 with tqdm (
161161 total = os .stat (file_path ).st_size ,
@@ -181,7 +181,7 @@ def upload_blob_gcs(
181181 in the backend.
182182 """
183183 params = {"storageInterface" : "gcs" , "objectName" : object_name }
184- presigned_json = self .get_request (endpoint , params = params )
184+ presigned_json = self .get_request (f" { endpoint } /presigned-url" , params = params )
185185 with open (file_path , "rb" ) as f :
186186 with tqdm (
187187 total = os .stat (file_path ).st_size ,
@@ -208,7 +208,7 @@ def upload_blob_azure(
208208 in the backend.
209209 """
210210 params = {"storageInterface" : "azure" , "objectName" : object_name }
211- presigned_json = self .get_request (endpoint , params = params )
211+ presigned_json = self .get_request (f" { endpoint } /presigned-url" , params = params )
212212 with open (file_path , "rb" ) as f :
213213 with tqdm (
214214 total = os .stat (file_path ).st_size ,
@@ -239,7 +239,7 @@ def transfer_blob(self, endpoint: str, file_path: str, object_name: str, body=No
239239 blob_path = f"{ UNBOX_STORAGE_PATH } /{ endpoint } /{ id } "
240240 try :
241241 os .makedirs (blob_path , exist_ok = True )
242- except OSError as _ :
242+ except OSError :
243243 raise UnboxException (f"Directory { blob_path } cannot be created" )
244244 shutil .copyfile (file_path , f"{ blob_path } /{ object_name } " )
245245 body ["storageUri" ] = f"local://{ blob_path } "
0 commit comments