The course settings `certificate_available_date` (CAD) and
`certificates_display_behavior` (CDB) were previously acting indedependantly
of one another. They now work in tandem. This change:
- limits CDB to a dropdown
- removes "early_with_info" and adds "end_with_date"
- only takes CAD into account if "end_with_date" is selected
- Moves CDB to the main course schedule settings page
- updates CourseOverview to validate these fields and choose sane
defaults if they aren't expected values
Certificates will now show under the following circumstances:
"Immediately upon passing"
certificate_availability_date = null
certificates_display_behavior = "early_no_info"
"End date of course"
certificate_availability_date = null
certificates_display_behavior = "end"
"A date after the course end date"
certificate_availability_date = <date>
certificates_display_behavior = "end_with_date"
The learning_sequences.use_for_outlines flag was recently added,
intended to serve the same purpose
as courseware.use_learning_seuqences_api. We do not need
both flags.
Furthermore, exposing either flag in the Courseware
Metadata API is neither necessary nor helpful, since
the easiest and quickest way for the Learning MFE to see
if the Learning Sequences API is enabled is to hit it,
and fall back to a different API if a 403 is returned.
This reverts commit 78f1e2b3bd.
TNL-8330
Previously, it would 404. While accurate, it's not a great user
experience. Users can be offered invalid jump_to paths in the normal
course of things, if course content disappears or they lose access
to it.
In both cases, they might be offered a resume URL in the courseware
that would be to a now-invalid location.
With this change, that invalid link will at least give them
*something* (the first unit in the course) rather than an error
page.
This also (unrelatedly) fixes an exception when the learning MFE
outline page tries to render a course that contains sequences
with no children.
AA-867
[MICROBA-1307]
Before this change a user would not be auto refunded if they had a
certificate in a course with any status. This had unintended
consequences. This change updates the logic to only block auto refund
for statuses that we do not want to refund on such as downloadable.
Add a Waffle Flag. When enabled, the courseware pages of the
Learning MFE should use the Learning Sequences HTTP API instead
of the Course Blocks HTTP API in order to load course structure
data. We expect that this switchover will lead to performance
improvements and a more comprehensible system.
(We are putting the switchover behind a temporary flag in order to
enable debugging, incremental rollout, and comparison testing.)
The flag is exposed to the MFE via the Course API.
As of this commit, the new flag is not enabled in any environment,
and the MFE does not have any code to act on the flag's value.
So, this commit on its own should have no production impact.
TNL-8330
and CourseSectionSequence to ensure that cascading deletes will occur to delete
the relation upon deletion of a foreign-keyed object.
This commit is phase 1 of 3 in order to ensure a smooth deploy. The phases:
1) Add separate through models for user partition groups, add fields to point to the
separate models, and start writing to those fields as well.
2) After all models have been re-generated, switch code over to use separate through
model fields backed by the separate through models.
3) After phase 2 is deployed smoothly, remove the original ManyToManyField fields
and rename the new fields to have the same name as the old fields.
* docs: ADR for new course apps API
This ADR proposes a new course apps API that is driven by a new coruse app
plugin type.
* Updated based on feedback
* Major changes to document structure
* Review feedback
* feat: Course Apps API
This adds a new concept called course apps. These are exposed via a new
"openedx.course_app" entrypoint, which helps the LMS and studio discover such
apps and list them in a new rest api for the same.
These course apps will drive the pages and resources view in the course authoring
MFE. This system will track which apps are enabled and which are disabled. It
also allows third-party apps to be listed here by using the plugin entrypoint.
* Apply feedback from review
This PR changes the preview URL redirect from Studio. Before when a user clicked on the course preview button to check unpublished changes, the preview in the New Experience would show the most recently published version of the course. The unpublished changes that the user was hoping to view are no present. At the moment users have been publishing the content to check it then having to republish the old version if they did not like the changes. As a short-term fix, this PR redirects to the Legacy experience where the preview option previously worked. Now the user can see the unpublished changes. A long-term fix is still being explored. This change will impact the Course Author.
A common usage pattern is to make an exam that is restricted to a
particular enrollment track. Since there is no UI in Studio to do this
at the sequence/subsection level, course authors instead restrict every
unit in the sequence to that track (e.g. "verified"). The legacy
courseware experience could handle this, but the Course Blocks API does
not. It is likely that we'll want to permit toggling this at the
sequence level, but regardless of whether we do that going forward, we
still have to deal with this kind of content data in existing courses.
An entirely empty sequence is useless, and currently breaks the
Courseware MFE browsing experience. This commit introduces the first
part of that fix, invoking the new Learning Sequences API to remove
sequences that the user shouldn't be allowed to know about. The plan is
to switch over the entire course outline from the Course Blocks API to
the Learning Sequences API, and this is the first small step in that
direction.
This also creates CourseWaffleFlag learning_sequences.use_for_outlines
to control the gradual rollout of this feature. This will start as a
very limited rollout to address courses that show this specific bug
(TNL-8377).
New learning_sequences public API call: public_api_available
This reverts commit c6192b8b40656c44ba0a89cdd569fb0c0e4f87c4.
The caching does little to save performance and in the case of whole
course interation, it has a netgative performance impact.
* feat: [BD-26] add the is_proctored value to SequenceMetadata API
* feat: add temporary flag for enabling/disabling proctored exams
* fix: change creation date
* fix: fix text indents
* fix: [BD-26] Remove redundant duplicated test.
Co-authored-by: Sagirov Eugeniy <sagirov19@gmail.com>
Co-authored-by: Igor Degtiarov <igor.degtiarov@raccoongang.com>
With this change, whenever a IntegritySignature is created or retrieved, the result will be cached into mem cache for future use. This will save round trip to database significantly for honor code check
- Remove the REDIRECT_TO_COURSEWARE_MICROFRONTEND waffle flag.
- Add a new COURSEWARE_USE_LEGACY_FRONTEND waffle flag that directs
all learners to the legacy courseware experience.
- Skip two failing a11y tests which fail due to the new default of
the courseware MFE.
TNL-8279
Sometimes learners have certificates in old course runs which've been
deleted. When this happens loading the learner's program progress can
result in 500 errors. This corrects those by choosing to count any
non-existent course the learner has certificates for as counting
towards program completion, effectively assuming that availability
dates have passed for all such courses.
Also fixes an error with a condition related to how we determine
whether an enrolled course is considered "in progress". The previous
version of the code had a bug that would result in a lot more courses
being marked "in progress" for the purpose of program completion than
actually were.
JIRA:EDUCATOR-5787
refactor: make xmodule & openedx independent of code in cms
The xmodule and openedx packages both contain code that is common
between LMS and CMS. The cms package is, of course,
contains CMS-specific code.
So, one prerequisite to extracting CMS into an independent service
will be making sure that lms, common, openedx, and the projects in
common/lib (xmodule, capa, etc.) are not coupled to any CMS-specific
features. This PR moves us towards that reality by making sure
that those packages are independent from cms from a Python-import
perspective, at least.
MST-861. The Django admin page for IntegritySignature only displays
the user and course_key for a signature. This adds the created and modified
fields, and will order signatures by the modified field.