Skip to content

Commit 436f010

Browse files
author
Lucas McDonald
committed
m
1 parent 161529e commit 436f010

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

Examples/runtimes/python/DynamoDBEncryption/src/basic_put_get_example/with_encrypted_table.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ def encrypted_table_put_get_example(
110110
table_configs[dynamodb_table_name] = table_config
111111
tables_config = DynamoDbTablesEncryptionConfig(table_encryption_configs=table_configs)
112112

113-
# 5. Create the EncryptedClient
113+
# 5. Create the EncryptedTable
114114
encrypted_table = EncryptedTable(
115115
table=boto3.resource("dynamodb").Table(dynamodb_table_name),
116116
encryption_config=tables_config,
@@ -128,7 +128,6 @@ def encrypted_table_put_get_example(
128128
}
129129

130130
put_item_request = {
131-
"TableName": dynamodb_table_name,
132131
"Item": item_to_encrypt,
133132
}
134133

@@ -142,7 +141,7 @@ def encrypted_table_put_get_example(
142141
# back the original item.
143142
key_to_get = {"partition_key": "BasicPutGetExample", "sort_key": 0}
144143

145-
get_item_request = {"TableName": dynamodb_table_name, "Key": key_to_get}
144+
get_item_request = {"Key": key_to_get}
146145

147146
get_item_response = encrypted_table.get_item(**get_item_request)
148147

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
22
# SPDX-License-Identifier: Apache-2.0
3-
"""Test suite for the EncryptedClient example."""
3+
"""Test suite for the EncryptedTable example."""
44
import pytest
55

66
from ...src.basic_put_get_example.with_encrypted_table import encrypted_table_put_get_example
@@ -9,7 +9,7 @@
99

1010

1111
def test_encrypted_table_put_get_example():
12-
"""Test function for encrypt and decrypt using the EncryptedClient example."""
12+
"""Test function for encrypt and decrypt using the EncryptedTable example."""
1313
test_kms_key_id = "arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f"
1414
test_dynamodb_table_name = "DynamoDbEncryptionInterceptorTestTable"
1515
encrypted_table_put_get_example(test_kms_key_id, test_dynamodb_table_name)

0 commit comments

Comments
 (0)