File tree 1 file changed +8
-8
lines changed
1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -392,16 +392,16 @@ def _handle_staging_get(
392
392
if local_file is None :
393
393
raise Error ("Cannot perform GET without specifying a local_file" )
394
394
395
- with open (local_file , "wb" ) as fp :
396
- r = requests .get (url = presigned_url , headers = headers )
395
+ r = requests .get (url = presigned_url , headers = headers )
397
396
398
- # response.ok verifies the status code is not between 400-600.
399
- # Any 2xx or 3xx will evaluate r.ok == True
400
- if not r .ok :
401
- raise Error (
402
- f"Staging operation over HTTP was unsuccessful: { r .status_code } -{ r .text } "
403
- )
397
+ # response.ok verifies the status code is not between 400-600.
398
+ # Any 2xx or 3xx will evaluate r.ok == True
399
+ if not r .ok :
400
+ raise Error (
401
+ f"Staging operation over HTTP was unsuccessful: { r .status_code } -{ r .text } "
402
+ )
404
403
404
+ with open (local_file , "wb" ) as fp :
405
405
fp .write (r .content )
406
406
407
407
def _handle_staging_remove (self , presigned_url : str , headers : dict = None ):
You can’t perform that action at this time.
0 commit comments