Skip to content

Commit df886d0

Browse files
author
Harinath
committed
formatting fixed ++ description fix.
1 parent 42b0ccd commit df886d0

File tree

3 files changed

+86
-143
lines changed

3 files changed

+86
-143
lines changed

pydanticrud/backends/dynamodb.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -416,15 +416,15 @@ def delete(self, key):
416416
def batch_save(self, items: list) -> dict:
417417
"""
418418
This function is to write multiple records in to dynamodb and returns unprocessed records in dict
419-
if something gone wrong with the record.This will by default try 3 time if any unprocessed
420-
records exists in result. Currently, batch_write is not supporting ConditionExpression
419+
if something gone wrong with the record.Currently, batch_write is not supporting ConditionExpression
421420
Refer docs:
422421
https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/dynamodb/client/batch_write_item.html
423422
"""
424423
# Prepare the batch write requests
425424
request_items = {self.table_name: []}
426425

427-
# chunk list for size limit of 25 items to write using this batch_write operation refer below.
426+
# chunk list for size limit of 25 items to write using this batch_write operation refer below.However
427+
# we are just trying with 20 items.
428428
# https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/dynamodb/client/batch_write_item.html#:~:text=The%20BatchWriteItem%20operation,Data%20Types.
429429
for chunk in chunk_list(items, 20):
430430
serialized_items = [self.serializer.serialize_record(item.dict(by_alias=True)) for item in chunk]

tests/random_values.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ def random_datetime():
1515
random.randint(1, 28),
1616
random.randint(1, 12),
1717
random.randint(1, 59),
18-
0,
18+
0
1919
)
2020

2121

0 commit comments

Comments
 (0)