Feb-13-2018, 06:41 PM
Hello,
I'm trying to use a python script to download a file from s3 to my Windows 10 laptop. I'm running the
prompt "as administrator". I have given everyone full access to the folder I'm trying to write the file
to, but windows is still giving an "access denied" error.
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python27\lib\site-packages\boto3\s3\inject.py", line 168, in bucket_download_file
ExtraArgs=ExtraArgs, Callback=Callback, Config=Config)
File "C:\Python27\lib\site-packages\boto3\s3\inject.py", line 130, in download_file
extra_args=ExtraArgs, callback=Callback)
File "C:\Python27\lib\site-packages\boto3\s3\transfer.py", line 307, in download_file
future.result()
File "C:\Python27\lib\site-packages\s3transfer\futures.py", line 73, in result
return self._coordinator.result()
File "C:\Python27\lib\site-packages\s3transfer\futures.py", line 233, in result
raise self._exception
WindowsError: [Error 5] Access is denied: 'C:\\data'
I'm new to Python, can anyone help with this? Thank You
I'm trying to use a python script to download a file from s3 to my Windows 10 laptop. I'm running the
prompt "as administrator". I have given everyone full access to the folder I'm trying to write the file
to, but windows is still giving an "access denied" error.
1 2 3 |
import boto3 s3 = boto3.resource( 's3' ) s3.Bucket( 'kapps2.services-exchange.com' ).download_file( 'myconfig.py' , 'C:\data' ) |
File "<stdin>", line 1, in <module>
File "C:\Python27\lib\site-packages\boto3\s3\inject.py", line 168, in bucket_download_file
ExtraArgs=ExtraArgs, Callback=Callback, Config=Config)
File "C:\Python27\lib\site-packages\boto3\s3\inject.py", line 130, in download_file
extra_args=ExtraArgs, callback=Callback)
File "C:\Python27\lib\site-packages\boto3\s3\transfer.py", line 307, in download_file
future.result()
File "C:\Python27\lib\site-packages\s3transfer\futures.py", line 73, in result
return self._coordinator.result()
File "C:\Python27\lib\site-packages\s3transfer\futures.py", line 233, in result
raise self._exception
WindowsError: [Error 5] Access is denied: 'C:\\data'
I'm new to Python, can anyone help with this? Thank You