Skip to content

Commit

Permalink
fix: updated goal reminder email time logger
Browse files Browse the repository at this point in the history
  • Loading branch information
AhtishamShahid committed Dec 18, 2024
1 parent 98214a5 commit f427070
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Command to trigger sending reminder emails for learners to achieve their Course Goals
"""
import time
from datetime import date, datetime, timedelta
from eventtracking import tracker
import logging
Expand Down Expand Up @@ -119,9 +120,9 @@ def send_ace_message(goal, session_id):

with emulate_http_request(site, user):
try:
start_time = datetime.now()
start_time = time.perf_counter()
ace.send(msg)
end_time = datetime.now()
end_time = time.perf_counter()
log.info(f"Goal Reminder for {user.id} for course {goal.course_key} sent in {end_time - start_time} "
f"using {'SES' if is_ses_enabled else 'others'}")
except Exception as exc: # pylint: disable=broad-except
Expand Down
2 changes: 2 additions & 0 deletions lms/envs/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -5640,3 +5640,5 @@ def _should_send_learning_badge_events(settings):
# .. toggle_creation_date: 2024-11-10
# .. toggle_target_removal_date: 2025-06-01
USE_EXTRACTED_VIDEO_BLOCK = False

DISABLE_FORUM_V2 = True

0 comments on commit f427070

Please sign in to comment.