django-not-configured is an error raised by pylint (with
the pylint-django plugin) when it's not correctly configured.
We should not be applying lint amnesty for such a violation.
When this flag is enabled, users will be 50/50 bucketed into an
experiment where users get course highlights and nudges from an
external service (like sailthru or braze) rather than from
edx-platform via ACE.
AA-661
Since Course Highlights aren't necessarily weekly (self-paced courses),
update the language to be more generic. And then includes a bug fix to
not send highlights to learners after they have unenrolled from a course.
When CourseNextSectionUpdate was created, it incorporated Personalized
Learner Schedules logic which didn't take into account release dates of
content and was only intended for self-paced courses that always have
all content released. This caused a bug where instructor-paced courses
could receive an update about content that had not been released yet.
This PR turns the CourseUpdateResolver back on for instructor-paced
courses so they can go back to receiving weekly highlights.
Inside content_highlights.py, we had code to calculate due dates
for when there isn't graded content, but we could only reach that
code path if the user had an assignment with a due date at the
target date. Now we will check for all learners who could be in
range of having an update and let the code in content_highlights.py
decide if a highlight should be sent
This uses the new names introduced in edx-django-utils
3.8.0 (edx/edx-django-utils#59), which we're already using, as
well as updating a few other locations where we incorrectly refer
to New Relic custom metrics instead of custom attributes.
Includes a couple of unrelated lint fixes in a file I modified.
- send course emails to users based on whichever date is later,
sedule start date or course start date. This addresses the
scenario when a user enrolls in a self paced course before it
has actually started.
The content highlights code assumed due dates existed on all
sections. But we recently broke that assumption. So now we
recalculate the spread of sections across the expected duration
ourselves rather than rely on due dates.
Currently there is no option to schedule bulk emails to be sent
out at a specific time for instructor led courses. It would reduce
the effort required to create an engaging course if instructor led
course teams had the option to turn on weekly highlight emails as
well.
PROD-575
Scheduled emails show "unsubscribe" link if waffle switch
`schedules.course_update_show_unsubscribe` is enabled, and
settings.ACE_ENABLED_POLICIES respects `bulk_email_optout`.
API endpoint allows GET/POST requests, which:
* GET asks for confirmation of opt-out
* POST accepts "unsubscribe" or "cancel", where "unsubscribe" creates the
Optout entry, and "cancel" does nothing.
Fixes flaky tests:
* The resolvers handle users in "bins", which are groups that depend on the user ID.
* The test user ID varies depending on the test order.
* This change ensures that the bin requested matches the user for the test.
Scheduled emails show "unsubscribe" link if waffle switch `schedules.course_update_show_unsubscribe` is enabled, and
settings.ACE_ENABLED_POLICIES respects `bulk_email_optout`.
API endpoint allows GET/POST requests, which:
* GET asks for confirmation of opt-out
* POST accepts "unsubscribe" or "cancel", where "unsubscribe" creates the
Optout entry, and "cancel" does nothing.