Skip to content

Commit

Permalink
fix: DeliveryStream was causing exceptions when disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
baolsen committed Feb 22, 2023
1 parent 23a2996 commit 740c765
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions clickopsnotifier/delivery_stream.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
import boto3
import json
import logging


class FakeClient:
def put_record_batch(self, Records=None):
print(f"FakeClient put_record_batch: {len(Records)} records")
def put_record_batch(self, **kwargs):
num_records = len(kwargs.get("Records", []))
logging.debug(f"FakeClient put_record_batch: {num_records} records")
return {"FailedPutCount": 0}


class DeliveryStream:

delivery_stream_name = None
client = None

Expand Down

0 comments on commit 740c765

Please sign in to comment.