Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: replace signal handler with event producer config #14

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,15 @@ Unreleased

*

[0.2.0] - 2024-02-09
************************************************

Changed
=======

* Remove hard coded signal handler so that openedx_events producer config can
be used to push events to event bus in a configurable way.

[0.1.7] - 2024-01-31
************************************************

Expand Down
12 changes: 9 additions & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,15 @@ settings: ``lms/envs/common.py``
# helps to configure probability of displaying the verification forms. Values in range 0 to 1 are allowed, where 0
# means never and 1 means always display. Default value is 0.5 i.e. 50% chance of displaying the form.
SHOW_SKILL_VERIFICATION_PROBABILITY = 0.5
# Optionally update topic name for verification event emitted when a user verifies tags for an xblock.
EVENT_BUS_XBLOCK_VERIFICATION_TOPIC = "learning-custom-xblock-skill-verfied"

# Include the XBLOCK_SKILL_VERIFIED signal in `EVENT_BUS_PRODUCER_CONFIG` to push the event to event bus
# Note: Include `openedx_events` in `INSTALLED_APPS` setting in the host application
# See https://docs.openedx.org/projects/openedx-events/en/latest/decisions/0014-new-event-bus-producer-config.html
# for more information about EVENT_BUS_PRODUCER_CONFIG
EVENT_BUS_PRODUCER_CONFIG = {
'org.openedx.learning.xblock.skill.verified.v1': {
'learning-xblock-skill-verfied': {'event_key_field': 'xblock_info.usage_key', 'enabled': True}
},
}

Developing
==========
Expand Down
47 changes: 36 additions & 11 deletions requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,34 +6,59 @@
#
asgiref==3.7.2
# via django
attrs==23.1.0
attrs==23.2.0
# via openedx-events
django==3.2.19
cffi==1.16.0
# via pynacl
click==8.1.7
# via edx-django-utils
django==3.2.24
# via
# -c https://raw.githubusercontent.com/edx/edx-lint/master/edx_lint/files/common_constraints.txt
# -r requirements/base.in
# django-crum
# django-model-utils
# django-waffle
# edx-django-utils
# openedx-events
# openedx-filters
django-crum==0.7.9
# via edx-django-utils
django-model-utils==4.3.1
# via -r requirements/base.in
edx-opaque-keys[django]==2.3.0
django-waffle==4.1.0
# via edx-django-utils
edx-django-utils==5.10.1
# via openedx-events
fastavro==1.7.4
edx-opaque-keys[django]==2.5.1
# via openedx-events
openedx-events==8.0.1
fastavro==1.9.3
# via openedx-events
newrelic==9.6.0
# via edx-django-utils
openedx-events==9.5.0
# via -r requirements/base.in
openedx-filters==1.3.0
openedx-filters==1.6.0
# via -r requirements/base.in
pbr==5.11.1
pbr==6.0.0
# via stevedore
psutil==5.9.8
# via edx-django-utils
pycparser==2.21
# via cffi
pymongo==3.13.0
# via edx-opaque-keys
pytz==2023.3
pynacl==1.5.0
# via edx-django-utils
pytz==2024.1
# via django
sqlparse==0.4.4
# via django
stevedore==5.1.0
# via edx-opaque-keys
typing-extensions==4.6.3
# via asgiref
# via
# edx-django-utils
# edx-opaque-keys
typing-extensions==4.9.0
# via
# asgiref
# edx-opaque-keys
27 changes: 16 additions & 11 deletions requirements/ci.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,30 +4,35 @@
#
# make upgrade
#
distlib==0.3.6
distlib==0.3.8
# via virtualenv
filelock==3.12.2
filelock==3.13.1
# via
# tox
# virtualenv
packaging==23.1
# via tox
platformdirs==3.5.3
# via virtualenv
pluggy==1.0.0
packaging==23.2
# via
# pyproject-api
# tox
platformdirs==4.2.0
# via
# tox
# virtualenv
pluggy==1.4.0
# via tox
py==1.11.0
# via tox
six==1.16.0
# via tox
tomli==2.0.1
# via tox
# via
# pyproject-api
# tox
tox==3.28.0
# via
# -c https://raw.githubusercontent.com/edx/edx-lint/master/edx_lint/files/common_constraints.txt
# -r requirements/ci.in
# tox-battery
tox-battery==0.6.1
tox-battery==0.6.2
# via -r requirements/ci.in
virtualenv==20.23.0
virtualenv==20.25.0
# via tox
Loading
Loading