Skip to content

Commit 1075f07

Browse files
author
me
committed
add action attribute to CheckpointInput
1 parent ce7811e commit 1075f07

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

amazon_kclpy/messages.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -333,13 +333,15 @@ def __init__(self, json_dict):
333333
* subSequenceNumber
334334
335335
The provided dictionary can optionally contain:
336+
* action
336337
* error
337338
338339
:param dict json_dict:
339340
"""
340341
self._sequence_number = json_dict["sequenceNumber"]
341342
self._sub_sequence_number = json_dict["subSequenceNumber"]
342343
self._error = json_dict.get("error", None)
344+
self._action = json_dict.get("action", "checkpoint")
343345

344346
@property
345347
def sequence_number(self):
@@ -373,6 +375,16 @@ def error(self):
373375
"""
374376
return self._error
375377

378+
@property
379+
def action(self):
380+
"""
381+
The action that spawned this message
382+
383+
:return: the original action value
384+
:rtype: str
385+
"""
386+
return self._action
387+
376388

377389
class Record(object):
378390
"""

0 commit comments

Comments
 (0)