-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Python] pyarrow: using role_arn with S3FileSystem results in Anonymous user error #38421
Comments
@MisterT314 have you been able to resolve this or work around it by any chance? I'm running into the same issue. |
@antonio-yuen-zocdoc A potential work around is to get the temporary AWS credentials using boto3 and then pass these directly to
I've used a similar approach to create an |
Seeing this issue in |
I am facing not the exact but a similar error using pyarrow version 10.0.0 for a glue job. After calling
I thought it could be due to role policies but the role has enough permission on the S3 bucket and the trust-relationship looks fine. I have come with a workaround using |
I got rid of pandas on my end and replaced with polars but I believe I was able to solve this issue using this doc. I believe I set this option on the to_parquet method: |
Hi, I'm initializing S3FileSystem with a role_arn, to get refreshable temporary credentials, as described in
https://arrow.apache.org/docs/python/generated/pyarrow.fs.S3FileSystem.html
The init call is the following:
A bit later I'm initializing a parquetwriter with the file system
I then get the error:
OSError: When initiating multiple part upload for key 'resources/01HBTZN7DBR1BE62S5TJRQDZXP/data.parquet' in bucket 'my-bucket-name': AWS Error ACCESS_DENIED during CreateMultipartUpload operation: Anonymous users cannot initiate multipart uploads. Please authenticate.
I expect that S3FileSystem would use STS to get temporary credentials like described in the documentation. The role is configured to allow the service (glue) to assume the role.
Pyarrow version 12.0.0
S3FS 2023.6.0
Using Pyarrow in a aws glue v4 environment
Component(s)
Python
The text was updated successfully, but these errors were encountered: