You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "kou (via GitHub)" <gi...@apache.org> on 2023/07/31 00:15:12 UTC

[GitHub] [arrow] kou commented on a diff in pull request #35312: GH-35409: [Python][Docs] Clarify S3FileSystem Credentials chain for EC2

kou commented on code in PR #35312:
URL: https://github.com/apache/arrow/pull/35312#discussion_r1278643546


##########
python/pyarrow/_s3fs.pyx:
##########
@@ -140,14 +140,20 @@ cdef class S3FileSystem(FileSystem):
     """
     S3-backed FileSystem implementation
 
-    If neither access_key nor secret_key are provided, and role_arn is also not
-    provided, then attempts to initialize from AWS environment variables,
-    otherwise both access_key and secret_key must be provided.
+    AWS access_key and secret_key can be provided explicitly.
 
     If role_arn is provided instead of access_key and secret_key, temporary
     credentials will be fetched by issuing a request to STS to assume the
     specified role.
 
+    If neither access_key nor secret_key are provided, and role_arn is also not
+    provided, then attempts establish the credentials automatically.
+    S3FileSystem will try the following methods, in order:
+
+    * `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, and `AWS_SESSION_TOKEN` environment variables
+    * configuration files such as `~/.aws/credentials` and `~/.aws/config`

Review Comment:
   We need two `` ` ``s for reStructuredText:
   
   ```suggestion
       * ``AWS_ACCESS_KEY_ID``, ``AWS_SECRET_ACCESS_KEY``, and ``AWS_SESSION_TOKEN`` environment variables
       * configuration files such as ``~/.aws/credentials`` and ``~/.aws/config``
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org