awscli 1.34.32__py3-none-any.whl → 1.35.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of awscli might be problematic. Click here for more details.
- awscli/__init__.py +1 -1
- awscli/customizations/s3/subcommands.py +36 -1
- awscli/customizations/s3/utils.py +13 -0
- {awscli-1.34.32.dist-info → awscli-1.35.0.dist-info}/METADATA +2 -2
- {awscli-1.34.32.dist-info → awscli-1.35.0.dist-info}/RECORD +13 -13
- {awscli-1.34.32.data → awscli-1.35.0.data}/scripts/aws +0 -0
- {awscli-1.34.32.data → awscli-1.35.0.data}/scripts/aws.cmd +0 -0
- {awscli-1.34.32.data → awscli-1.35.0.data}/scripts/aws_bash_completer +0 -0
- {awscli-1.34.32.data → awscli-1.35.0.data}/scripts/aws_completer +0 -0
- {awscli-1.34.32.data → awscli-1.35.0.data}/scripts/aws_zsh_completer.sh +0 -0
- {awscli-1.34.32.dist-info → awscli-1.35.0.dist-info}/LICENSE.txt +0 -0
- {awscli-1.34.32.dist-info → awscli-1.35.0.dist-info}/WHEEL +0 -0
- {awscli-1.34.32.dist-info → awscli-1.35.0.dist-info}/top_level.txt +0 -0
awscli/__init__.py
CHANGED
|
@@ -451,6 +451,17 @@ VALIDATE_SAME_S3_PATHS = {
|
|
|
451
451
|
)
|
|
452
452
|
}
|
|
453
453
|
|
|
454
|
+
CHECKSUM_MODE = {
|
|
455
|
+
'name': 'checksum-mode', 'choices': ['ENABLED'],
|
|
456
|
+
'help_text': 'To retrieve the checksum, this mode must be enabled. If the object has a '
|
|
457
|
+
'checksum, it will be verified.'
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
CHECKSUM_ALGORITHM = {
|
|
461
|
+
'name': 'checksum-algorithm', 'choices': ['CRC32', 'SHA256', 'SHA1', 'CRC32C'],
|
|
462
|
+
'help_text': 'Indicates the algorithm used to create the checksum for the object.'
|
|
463
|
+
}
|
|
464
|
+
|
|
454
465
|
TRANSFER_ARGS = [DRYRUN, QUIET, INCLUDE, EXCLUDE, ACL,
|
|
455
466
|
FOLLOW_SYMLINKS, NO_FOLLOW_SYMLINKS, NO_GUESS_MIME_TYPE,
|
|
456
467
|
SSE, SSE_C, SSE_C_KEY, SSE_KMS_KEY_ID, SSE_C_COPY_SOURCE,
|
|
@@ -459,7 +470,7 @@ TRANSFER_ARGS = [DRYRUN, QUIET, INCLUDE, EXCLUDE, ACL,
|
|
|
459
470
|
CONTENT_DISPOSITION, CONTENT_ENCODING, CONTENT_LANGUAGE,
|
|
460
471
|
EXPIRES, SOURCE_REGION, ONLY_SHOW_ERRORS, NO_PROGRESS,
|
|
461
472
|
PAGE_SIZE, IGNORE_GLACIER_WARNINGS, FORCE_GLACIER_TRANSFER,
|
|
462
|
-
REQUEST_PAYER]
|
|
473
|
+
REQUEST_PAYER, CHECKSUM_MODE, CHECKSUM_ALGORITHM]
|
|
463
474
|
|
|
464
475
|
|
|
465
476
|
def get_client(session, region, endpoint_url, verify, config=None):
|
|
@@ -1242,6 +1253,17 @@ class CommandParameters(object):
|
|
|
1242
1253
|
if self._should_emit_validate_s3_paths_warning():
|
|
1243
1254
|
self._emit_validate_s3_paths_warning()
|
|
1244
1255
|
|
|
1256
|
+
if params.get('checksum_algorithm'):
|
|
1257
|
+
self._raise_if_paths_type_incorrect_for_param(
|
|
1258
|
+
CHECKSUM_ALGORITHM['name'],
|
|
1259
|
+
params['paths_type'],
|
|
1260
|
+
['locals3', 's3s3'])
|
|
1261
|
+
if params.get('checksum_mode'):
|
|
1262
|
+
self._raise_if_paths_type_incorrect_for_param(
|
|
1263
|
+
CHECKSUM_MODE['name'],
|
|
1264
|
+
params['paths_type'],
|
|
1265
|
+
['s3local'])
|
|
1266
|
+
|
|
1245
1267
|
# If the user provided local path does not exist, hard fail because
|
|
1246
1268
|
# we know that we will not be able to upload the file.
|
|
1247
1269
|
if 'locals3' == params['paths_type'] and not params['is_stream']:
|
|
@@ -1325,6 +1347,19 @@ class CommandParameters(object):
|
|
|
1325
1347
|
f"{self.parameters['src']} - {self.parameters['dest']}"
|
|
1326
1348
|
)
|
|
1327
1349
|
|
|
1350
|
+
def _raise_if_paths_type_incorrect_for_param(self, param, paths_type, allowed_paths):
|
|
1351
|
+
if paths_type not in allowed_paths:
|
|
1352
|
+
expected_usage_map = {
|
|
1353
|
+
'locals3': '<LocalPath> <S3Uri>',
|
|
1354
|
+
's3s3': '<S3Uri> <S3Uri>',
|
|
1355
|
+
's3local': '<S3Uri> <LocalPath>',
|
|
1356
|
+
's3': '<S3Uri>'
|
|
1357
|
+
}
|
|
1358
|
+
raise ValueError(
|
|
1359
|
+
f"Expected {param} parameter to be used with one of following path formats: "
|
|
1360
|
+
f"{', '.join([expected_usage_map[path] for path in allowed_paths])}. Instead, received {expected_usage_map[paths_type]}."
|
|
1361
|
+
)
|
|
1362
|
+
|
|
1328
1363
|
def _normalize_s3_trailing_slash(self, paths):
|
|
1329
1364
|
for i, path in enumerate(paths):
|
|
1330
1365
|
if path.startswith('s3://'):
|
|
@@ -474,12 +474,14 @@ class RequestParamsMapper(object):
|
|
|
474
474
|
cls._set_sse_request_params(request_params, cli_params)
|
|
475
475
|
cls._set_sse_c_request_params(request_params, cli_params)
|
|
476
476
|
cls._set_request_payer_param(request_params, cli_params)
|
|
477
|
+
cls._set_checksum_algorithm_param(request_params, cli_params)
|
|
477
478
|
|
|
478
479
|
@classmethod
|
|
479
480
|
def map_get_object_params(cls, request_params, cli_params):
|
|
480
481
|
"""Map CLI params to GetObject request params"""
|
|
481
482
|
cls._set_sse_c_request_params(request_params, cli_params)
|
|
482
483
|
cls._set_request_payer_param(request_params, cli_params)
|
|
484
|
+
cls._set_checksum_mode_param(request_params, cli_params)
|
|
483
485
|
|
|
484
486
|
@classmethod
|
|
485
487
|
def map_copy_object_params(cls, request_params, cli_params):
|
|
@@ -492,6 +494,7 @@ class RequestParamsMapper(object):
|
|
|
492
494
|
cls._set_sse_c_and_copy_source_request_params(
|
|
493
495
|
request_params, cli_params)
|
|
494
496
|
cls._set_request_payer_param(request_params, cli_params)
|
|
497
|
+
cls._set_checksum_algorithm_param(request_params, cli_params)
|
|
495
498
|
|
|
496
499
|
@classmethod
|
|
497
500
|
def map_head_object_params(cls, request_params, cli_params):
|
|
@@ -534,6 +537,16 @@ class RequestParamsMapper(object):
|
|
|
534
537
|
if cli_params.get('request_payer'):
|
|
535
538
|
request_params['RequestPayer'] = cli_params['request_payer']
|
|
536
539
|
|
|
540
|
+
@classmethod
|
|
541
|
+
def _set_checksum_mode_param(cls, request_params, cli_params):
|
|
542
|
+
if cli_params.get('checksum_mode'):
|
|
543
|
+
request_params['ChecksumMode'] = cli_params['checksum_mode']
|
|
544
|
+
|
|
545
|
+
@classmethod
|
|
546
|
+
def _set_checksum_algorithm_param(cls, request_params, cli_params):
|
|
547
|
+
if cli_params.get('checksum_algorithm'):
|
|
548
|
+
request_params['ChecksumAlgorithm'] = cli_params['checksum_algorithm']
|
|
549
|
+
|
|
537
550
|
@classmethod
|
|
538
551
|
def _set_general_object_params(cls, request_params, cli_params):
|
|
539
552
|
# Parameters set in this method should be applicable to the following
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: awscli
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.35.0
|
|
4
4
|
Summary: Universal Command Line Environment for AWS.
|
|
5
5
|
Home-page: http://aws.amazon.com/cli/
|
|
6
6
|
Author: Amazon Web Services
|
|
@@ -23,7 +23,7 @@ Classifier: Programming Language :: Python :: 3.11
|
|
|
23
23
|
Classifier: Programming Language :: Python :: 3.12
|
|
24
24
|
Requires-Python: >= 3.8
|
|
25
25
|
License-File: LICENSE.txt
|
|
26
|
-
Requires-Dist: botocore (==1.35.
|
|
26
|
+
Requires-Dist: botocore (==1.35.34)
|
|
27
27
|
Requires-Dist: docutils (<0.17,>=0.10)
|
|
28
28
|
Requires-Dist: s3transfer (<0.11.0,>=0.10.0)
|
|
29
29
|
Requires-Dist: PyYAML (<6.1,>=3.10)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
awscli/__init__.py,sha256=
|
|
1
|
+
awscli/__init__.py,sha256=09oDL3b1wjy0Ojep-G6ZYhH2DAubPa8VQyU2bqVf8dE,1533
|
|
2
2
|
awscli/__main__.py,sha256=iBjOg0tBxNlhzTi_tyc1G0SMGBvHMVvBJzX3JqYaooY,662
|
|
3
3
|
awscli/alias.py,sha256=Us9pvP8Zplbr1W4N3rE5gxicWLqlRG3l_9VPskxafgs,11313
|
|
4
4
|
awscli/argparser.py,sha256=3Pxx-vWytdV985Y6MIl9DeutUXyehIvACIs_PDby8GI,7650
|
|
@@ -198,9 +198,9 @@ awscli/customizations/s3/filters.py,sha256=OuQUr6XAMkS1i6GO65_L7NbL7kwgmKT2ghWhv
|
|
|
198
198
|
awscli/customizations/s3/results.py,sha256=L19gi3CtJYeHqWIWuIVcbj82Dshw2g5jNX8PFidcC2U,26625
|
|
199
199
|
awscli/customizations/s3/s3.py,sha256=Igwsn89G7i9M4nShjzcFmwlCVXvpfgmoyEf9wpNLXdk,2739
|
|
200
200
|
awscli/customizations/s3/s3handler.py,sha256=FSeCyMRi2EwNDNR329geVV8vZpap1OiSscNS-3sCCP0,23299
|
|
201
|
-
awscli/customizations/s3/subcommands.py,sha256=
|
|
201
|
+
awscli/customizations/s3/subcommands.py,sha256=oz_85AnDfeBlodJi077LZsJr564XC1crFSiBz37hVfM,62167
|
|
202
202
|
awscli/customizations/s3/transferconfig.py,sha256=7MW4hi90N5mLeQBlmVxs9J5ixRjejp1F4uPmGGF3TME,4472
|
|
203
|
-
awscli/customizations/s3/utils.py,sha256=
|
|
203
|
+
awscli/customizations/s3/utils.py,sha256=Wcnx32I2P5E7A2Qh0ONG6IXWvnmz3NxNBtGUrGI61VQ,34213
|
|
204
204
|
awscli/customizations/s3/syncstrategy/__init__.py,sha256=BFJ0dbdWkUBgJ2qav1Jhz06SddTMIeahxSaW_H0vop0,565
|
|
205
205
|
awscli/customizations/s3/syncstrategy/base.py,sha256=WHvsh6p3KhF3GsX0h05eYTh1DohNG2TyeEXUW8xQ6ZU,10113
|
|
206
206
|
awscli/customizations/s3/syncstrategy/delete.py,sha256=y-KSRQE14bZY9jQfJJx0WbZ8UyX6juKkDhS8lwC9ed8,1313
|
|
@@ -5953,13 +5953,13 @@ awscli/topics/return-codes.rst,sha256=d9lpNFZwD75IiYcDEADQzu-4QiR8P28UPHkrNwPV5J
|
|
|
5953
5953
|
awscli/topics/s3-config.rst,sha256=FwwCczTylrSLwELuDQ-VA8sCI7ruwV9PEJJrqxjUeG0,11502
|
|
5954
5954
|
awscli/topics/s3-faq.rst,sha256=sS5jKHF_7X5eiGwpUg7aTqQt2zCRN-m_xXOcE0Bme0Q,1899
|
|
5955
5955
|
awscli/topics/topic-tags.json,sha256=6lUSrs3FKCZNRSQMnjcXNgWyRNGjZIeur1988a4IO5o,1577
|
|
5956
|
-
awscli-1.
|
|
5957
|
-
awscli-1.
|
|
5958
|
-
awscli-1.
|
|
5959
|
-
awscli-1.
|
|
5960
|
-
awscli-1.
|
|
5961
|
-
awscli-1.
|
|
5962
|
-
awscli-1.
|
|
5963
|
-
awscli-1.
|
|
5964
|
-
awscli-1.
|
|
5965
|
-
awscli-1.
|
|
5956
|
+
awscli-1.35.0.data/scripts/aws,sha256=r24FExgs0-JjILTQ3XZAqXBYE4SV6UMTtALkLGAj86g,805
|
|
5957
|
+
awscli-1.35.0.data/scripts/aws.cmd,sha256=s46DkC6LNgX63CIkzxxbPnFMJ6DRDBkvc88GnWa8Pvg,1432
|
|
5958
|
+
awscli-1.35.0.data/scripts/aws_bash_completer,sha256=RRpoEGJRagRzyHZKZZOwpltuVYv2EoiZsdXhmyWPZ54,204
|
|
5959
|
+
awscli-1.35.0.data/scripts/aws_completer,sha256=oC9kuMDlWE47dWk_4xjPde2PQvN-M0vND0J4YSLabVQ,1126
|
|
5960
|
+
awscli-1.35.0.data/scripts/aws_zsh_completer.sh,sha256=Qm6Z8ejNAMzpJjaT0pzqxbSDT2zxdmzVe5haRA7qLoc,1808
|
|
5961
|
+
awscli-1.35.0.dist-info/LICENSE.txt,sha256=o5XhFlwu0OK_BBrijlKCRa7dQAm36UrUB3gCV_cEr8E,549
|
|
5962
|
+
awscli-1.35.0.dist-info/METADATA,sha256=Q7yUG1Kkbn_6AJmn60CHCXTtVlOeoE2pU-1NU99C2tU,11330
|
|
5963
|
+
awscli-1.35.0.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
|
|
5964
|
+
awscli-1.35.0.dist-info/top_level.txt,sha256=vt9wXFr1_nGYK6abhJgt6zY3fULe4JSZedm_5XOM9S0,7
|
|
5965
|
+
awscli-1.35.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|