Skip to content

Commit

Permalink
feat!: remove deprecated signal parameter from consumer (#171)
Browse files Browse the repository at this point in the history
  • Loading branch information
Rebecca Graber authored May 17, 2023
1 parent be6c4a8 commit e466e21
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 10 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ Change Log
Unreleased
**********

[5.0.0] - 2023-05-17
********************
Changed
=======
* **BREAKING CHANGE**: Removed deprecated ``signal`` argument from consumer initialization

[4.0.1] - 2023-05-10
********************
Fixed
Expand Down
2 changes: 1 addition & 1 deletion edx_event_bus_kafka/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
from edx_event_bus_kafka.internal.consumer import KafkaEventConsumer
from edx_event_bus_kafka.internal.producer import KafkaEventProducer, create_producer

__version__ = '4.0.1'
__version__ = '5.0.0'
3 changes: 1 addition & 2 deletions edx_event_bus_kafka/internal/consumer.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,12 @@ class KafkaEventConsumer(EventBusConsumer):
Attributes:
topic: Topic to consume (without environment prefix).
group_id: Consumer group id.
signal: DEPRECATED Type of signal to emit from consumed messages. Will be removed in a future version
consumer: Actual kafka consumer instance.
offset_time: The timestamp (in ISO format) that we would like to reset the consumers to. If this is used, the
consumers will only reset the offsets of the topic but will not actually consume and process any messages.
"""

def __init__(self, topic, group_id, signal=None, offset_time=None): # pylint: disable=unused-argument
def __init__(self, topic, group_id, offset_time=None):
if confluent_kafka is None: # pragma: no cover
raise Exception('Library confluent-kafka not available. Cannot create event consumer.')

Expand Down
4 changes: 2 additions & 2 deletions requirements/base.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
-c constraints.txt

Django # Web application framework
# openedx-events 7.1.0 introduces consumer api and consume_events command
openedx-events>=7.1.0 # Events API
# openedx-events 8.0.0 removes an argument from consumer initialization
openedx-events>=8.0.0 # Events API
edx_django_utils
edx_toggles
2 changes: 1 addition & 1 deletion requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ markupsafe==2.1.2
# via jinja2
newrelic==8.8.0
# via edx-django-utils
openedx-events==7.2.0
openedx-events==8.0.0
# via -r requirements/base.in
pbr==5.11.1
# via stevedore
Expand Down
2 changes: 1 addition & 1 deletion requirements/dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ newrelic==8.8.0
# via
# -r requirements/quality.txt
# edx-django-utils
openedx-events==7.2.0
openedx-events==8.0.0
# via -r requirements/quality.txt
packaging==23.1
# via
Expand Down
2 changes: 1 addition & 1 deletion requirements/doc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ newrelic==8.8.0
# via
# -r requirements/test.txt
# edx-django-utils
openedx-events==7.2.0
openedx-events==8.0.0
# via -r requirements/test.txt
packaging==23.1
# via
Expand Down
2 changes: 1 addition & 1 deletion requirements/quality.txt
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ newrelic==8.8.0
# via
# -r requirements/test.txt
# edx-django-utils
openedx-events==7.2.0
openedx-events==8.0.0
# via -r requirements/test.txt
packaging==23.1
# via
Expand Down
2 changes: 1 addition & 1 deletion requirements/test.txt
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ newrelic==8.8.0
# via
# -r requirements/base.txt
# edx-django-utils
openedx-events==7.2.0
openedx-events==8.0.0
# via -r requirements/base.txt
packaging==23.1
# via pytest
Expand Down

0 comments on commit e466e21

Please sign in to comment.