Skip to content

Add no_sign_request for S3Client#164

Merged
pjbull merged 3 commits into
masterfrom
38-no-sign-kwarg
Sep 8, 2021
Merged

Add no_sign_request for S3Client#164
pjbull merged 3 commits into
masterfrom
38-no-sign-kwarg

Conversation

@pjbull

@pjbull pjbull commented Sep 7, 2021

Copy link
Copy Markdown
Member

S3 requires explicitly not signing requests if users want anonymous access. To access a public bucket without any credentials configured, you need to instantiate a client that will not sign requests.

This PR adds a no_sign_request kwarg to S3Client that mimics the way a user might pass --no-sign-request with the AWS CLI to access public assets anonymously.

Closes #38

@pjbull pjbull requested a review from jayqi September 7, 2021 21:53
@github-actions

github-actions Bot commented Sep 7, 2021

Copy link
Copy Markdown
Contributor

@codecov

codecov Bot commented Sep 7, 2021

Copy link
Copy Markdown

Codecov Report

Merging #164 (4084423) into master (57b121b) will increase coverage by 0.1%.
The diff coverage is 100.0%.

@@           Coverage Diff            @@
##           master    #164     +/-   ##
========================================
+ Coverage    93.9%   94.1%   +0.1%     
========================================
  Files          21      21             
  Lines        1179    1183      +4     
========================================
+ Hits         1108    1114      +6     
+ Misses         71      69      -2     
Impacted Files Coverage Δ
cloudpathlib/s3/s3client.py 93.4% <100.0%> (+0.2%) ⬆️
cloudpathlib/gs/gsclient.py 94.0% <0.0%> (+2.0%) ⬆️

Comment thread HISTORY.md Outdated
Comment thread tests/test_s3_specific.py
Comment thread tests/test_s3_specific.py
Comment thread cloudpathlib/s3/s3client.py
Comment thread HISTORY.md Outdated
pjbull and others added 2 commits September 7, 2021 15:59
Co-authored-by: Jay Qi <2721979+jayqi@users.noreply.github.com>
@jayqi jayqi self-requested a review September 8, 2021 00:17
@pjbull pjbull merged commit cf76d62 into master Sep 8, 2021
@pjbull pjbull deleted the 38-no-sign-kwarg branch September 8, 2021 00:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support anonymous through boto to work with public S3 assets

2 participants