Skip to content
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

Implement content type propagation #226

Merged
merged 12 commits into from
May 19, 2022
Merged

Implement content type propagation #226

merged 12 commits into from
May 19, 2022

Conversation

pjbull
Copy link
Member

@pjbull pjbull commented May 16, 2022

Implements propagating content types to all of the cloud providers. Does so by adding a kwarg to all clients content_type_method that by default is set to the built-in mimetypes.guess_type.

Includes tests and documentation.

Changes looks bigger than it is because all of our Local testing resources and Mocks had to be updated to track content types that were set so that we could test them.

Closes #222

@github-actions
Copy link
Contributor

github-actions bot commented May 16, 2022

@pjbull pjbull force-pushed the 222-guess-mimetype branch from 72277c3 to 6083928 Compare May 16, 2022 05:35
@pjbull pjbull requested a review from jayqi May 16, 2022 05:36
@codecov-commenter
Copy link

codecov-commenter commented May 16, 2022

Codecov Report

Merging #226 (4fac4a0) into master (85268c8) will decrease coverage by 0.1%.
The diff coverage is 93.1%.

@@           Coverage Diff            @@
##           master    #226     +/-   ##
========================================
- Coverage    94.8%   94.7%   -0.2%     
========================================
  Files          21      21             
  Lines        1256    1287     +31     
========================================
+ Hits         1191    1219     +28     
- Misses         65      68      +3     
Impacted Files Coverage Δ
cloudpathlib/local/localclient.py 96.4% <87.5%> (-1.1%) ⬇️
cloudpathlib/s3/s3client.py 95.4% <90.9%> (-0.7%) ⬇️
cloudpathlib/azure/azblobclient.py 94.2% <92.8%> (-0.5%) ⬇️
cloudpathlib/client.py 87.9% <100.0%> (+0.4%) ⬆️
cloudpathlib/gs/gsclient.py 94.4% <100.0%> (+0.2%) ⬆️

@pjbull pjbull force-pushed the 222-guess-mimetype branch from d254348 to 6fb75b1 Compare May 16, 2022 16:06
cloudpathlib/azure/azblobclient.py Outdated Show resolved Hide resolved
cloudpathlib/azure/azblobclient.py Show resolved Hide resolved
docs/docs/authentication.md Outdated Show resolved Hide resolved
HISTORY.md Outdated Show resolved Hide resolved
@pjbull
Copy link
Member Author

pjbull commented May 19, 2022

Thanks @jayqi for review! Integrated all your comments.

Copy link
Member

@jayqi jayqi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, aside from small typo. I think you can bump the version in setup.py and then release after merging.

HISTORY.md Outdated Show resolved Hide resolved
HISTORY.md Outdated Show resolved Hide resolved
pjbull and others added 2 commits May 19, 2022 08:13
Co-authored-by: Jay Qi <[email protected]>
Co-authored-by: Jay Qi <[email protected]>
@pjbull pjbull merged commit da86719 into master May 19, 2022
@pjbull pjbull deleted the 222-guess-mimetype branch May 19, 2022 15:42
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.

S3Path does not set object mime-type when uploading a file on S3
3 participants