@@ -260,8 +260,11 @@ def batch_get(cls, items, consistent_read=None, attributes_to_get=None):
260
260
while items :
261
261
if len (keys_to_get ) == BATCH_GET_PAGE_LIMIT :
262
262
while keys_to_get :
263
- page , unprocessed_keys = cls ._batch_get_page (keys_to_get , consistent_read = None ,
264
- attributes_to_get = None )
263
+ page , unprocessed_keys = cls ._batch_get_page (
264
+ keys_to_get ,
265
+ consistent_read = consistent_read ,
266
+ attributes_to_get = attributes_to_get
267
+ )
265
268
for batch_item in page :
266
269
yield cls .from_raw_data (batch_item )
267
270
if unprocessed_keys :
@@ -282,7 +285,11 @@ def batch_get(cls, items, consistent_read=None, attributes_to_get=None):
282
285
})
283
286
284
287
while keys_to_get :
285
- page , unprocessed_keys = cls ._batch_get_page (keys_to_get , consistent_read = None , attributes_to_get = None )
288
+ page , unprocessed_keys = cls ._batch_get_page (
289
+ keys_to_get ,
290
+ consistent_read = consistent_read ,
291
+ attributes_to_get = attributes_to_get
292
+ )
286
293
for batch_item in page :
287
294
yield cls .from_raw_data (batch_item )
288
295
if unprocessed_keys :
@@ -1209,7 +1216,7 @@ def _batch_get_page(cls, keys_to_get, consistent_read, attributes_to_get):
1209
1216
"""
1210
1217
log .debug ("Fetching a BatchGetItem page" )
1211
1218
data = cls ._get_connection ().batch_get_item (
1212
- keys_to_get , consistent_read , attributes_to_get
1219
+ keys_to_get , consistent_read = consistent_read , attributes_to_get = attributes_to_get
1213
1220
)
1214
1221
cls ._throttle .add_record (data .get (CONSUMED_CAPACITY ))
1215
1222
item_data = data .get (RESPONSES ).get (cls .Meta .table_name )
0 commit comments