You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The idea is simple: you should pay for any queries to this bucket (not bucket owner). For this reason, in tools like awscli or s3cmd authors add --request-payer flag that confrims that you ready to pay money from your account for get access to bucket. For example, see aws/aws-cli#797.
Solution:
Typically, this argument named like {'RequestPayer': 'requester'} or {'x-amz-request-payer': 'requester'} (if we talking about boto3).
I can't pass "object_kwargs" to S3 connector, arguments resource_kwargs or multipart_upload_kwargs aren't suitable for this. For example, RequestPayer='requester' should be passed to any "get-like" method, here https://github.com/RaRe-Technologies/smart_open/blob/a621aebcb34069b0f7850784231c3eaac7e2b964/smart_open/s3.py#L143 and any s3_object.get call.
This code should show content of file after adding "object_kwargs" arguments (instead of exceptions)
Problem:
I trying to open file
s3://arxiv/pdf/arXiv_pdf_manifest.xml
but getAccessDenied
error.This happens because of
arxiv
bucket is https://docs.aws.amazon.com/AmazonS3/latest/dev/RequesterPaysBuckets.html.The idea is simple: you should pay for any queries to this bucket (not bucket owner). For this reason, in tools like
awscli
ors3cmd
authors add--request-payer
flag that confrims that you ready to pay money from your account for get access to bucket. For example, see aws/aws-cli#797.Solution:
Typically, this argument named like
{'RequestPayer': 'requester'}
or{'x-amz-request-payer': 'requester'}
(if we talking aboutboto3
).I can't pass "object_kwargs" to S3 connector, arguments
resource_kwargs
ormultipart_upload_kwargs
aren't suitable for this. For example,RequestPayer='requester'
should be passed to any "get-like" method, here https://github.com/RaRe-Technologies/smart_open/blob/a621aebcb34069b0f7850784231c3eaac7e2b964/smart_open/s3.py#L143 and anys3_object.get
call.This code should show content of file after adding "object_kwargs" arguments (instead of exceptions)
The text was updated successfully, but these errors were encountered: