aws-cli
aws-cli copied to clipboard
Add no-overwrite option to `s3 cp` and `s3 mv` commands
Issue #, if available: #2874
Description of changes:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Codecov Report
Merging #6095 (f82c4a3) into v2 (4172ada) will increase coverage by
0.00%
. The diff coverage is97.36%
.
:exclamation: Current head f82c4a3 differs from pull request most recent head 2bda3e5. Consider uploading reports for the commit 2bda3e5 to get more accurate results
@@ Coverage Diff @@
## v2 #6095 +/- ##
=======================================
Coverage 94.14% 94.15%
=======================================
Files 271 271
Lines 21550 21608 +58
=======================================
+ Hits 20288 20344 +56
- Misses 1262 1264 +2
Impacted Files | Coverage Δ | |
---|---|---|
awscli/customizations/s3/filters.py | 98.43% <97.22%> (-1.57%) |
:arrow_down: |
awscli/customizations/s3/subcommands.py | 97.24% <100.00%> (+0.01%) |
:arrow_up: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 4172ada...2bda3e5. Read the comment docs.
This seems like it would be prone to race condition issues since it's just a HEAD then a write.
@vz10 - hi! Any update on this PR?
Any update to this PR? I in need for no-overwrite option.. thanks!
you can't implement a no-overwrite option in S3. it's not possible to do without race conditions.
This doesn't fix the problem but may help some people out there in specific scenarios! https://github.com/jfstephe/aws-s3-lock
you can't implement a no-overwrite option in S3. it's not possible to do without race conditions.
"get item, do not upload if it exists" is what is requested here, and that is trivial to implement, nobody said it needs to be atomic
Hey everyone, thanks for this pull request and the discussion around it. We've made the decision to close this pull request, and leave the feature request open for tracking purposes. There is certainly value in the feature being requested here, but this isn't something we can really accept a pull request for, as there are implementation details that need to be handled internally. Please continue to 👍 the tracking issue (https://github.com/aws/aws-cli/issues/2874), and describe your use cases for such a feature in the replies.