From 42ff67e2c992789a04b2d5eba6024b60994a38df Mon Sep 17 00:00:00 2001 From: Helen Bailey Date: Wed, 30 Aug 2023 14:56:47 -0400 Subject: [PATCH] Fix bug where cloudtrail events were retrieved and added to queue twice (#169) Co-authored-by: Bill Wei --- extensions/eda/plugins/event_source/aws_cloudtrail.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/eda/plugins/event_source/aws_cloudtrail.py b/extensions/eda/plugins/event_source/aws_cloudtrail.py index 7847fcdf..5d5e34a8 100644 --- a/extensions/eda/plugins/event_source/aws_cloudtrail.py +++ b/extensions/eda/plugins/event_source/aws_cloudtrail.py @@ -91,9 +91,9 @@ async def main(queue: asyncio.Queue, args: dict[str, Any]) -> None: event_time = None event_ids = [] while True: - events = await _get_cloudtrail_events(client, params) if event_time is not None: params["StartTime"] = event_time + events = await _get_cloudtrail_events(client, params) events, c_event_time, c_event_ids = _get_events(events, event_ids) for event in events: