Skip to content

Commit

Permalink
feat: incorporate changes in 8.7.0 and add signal hander
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelRoytman authored and alangsto committed Oct 2, 2023
1 parent 267dc5f commit 7617f3b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
9 changes: 9 additions & 0 deletions edx_exams/apps/core/signals/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,21 @@
Signal handlers for the edx-exams application.
"""
from django.dispatch import receiver
<<<<<<< HEAD
from openedx_events.event_bus import get_producer
from openedx_events.learning.signals import EXAM_ATTEMPT_SUBMITTED


@receiver(EXAM_ATTEMPT_SUBMITTED)
def listen_for_exam_attempt_submitted(sender, signal, **kwargs): # pylint: disable=unused-argument
=======

from openedx_events.event_bus import get_producer
from openedx_events.learning.signals import EXAM_ATTEMPT_SUBMITTED

@receiver(EXAM_ATTEMPT_SUBMITTED)
def listen_for_exam_attempt_submitted(sender, signal, **kwargs):
>>>>>>> d324b9d (feat: incorporate changes in 8.7.0 and add signal hander)
"""
Publish EXAM_ATTEMPT_SUBMITTED signals onto the event bus.
"""
Expand Down
4 changes: 4 additions & 0 deletions edx_exams/apps/core/signals/signals.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,14 @@


def emit_exam_attempt_submitted_event(user, course_key, usage_key, exam_type):
<<<<<<< HEAD
"""
Emit the EXAM_ATTEMPT_SUBMITTED Open edX event.
"""
name = user.full_name or ''
=======
name=user.full_name or ''
>>>>>>> d324b9d (feat: incorporate changes in 8.7.0 and add signal hander)
user_data = UserData(
id=user.id,
is_active=user.is_active,
Expand Down

0 comments on commit 7617f3b

Please sign in to comment.