Commit Graph

4684 Commits

Author SHA1 Message Date
Matt Tuchfarber
63cb6a97ff Revert "feat: Reimagine certificate_availability_date and certificates_display_behavior" 2021-07-07 16:53:05 -04:00
Matt Tuchfarber
2a7106acfb feat: reimagine certificate display settings
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"
2021-07-06 16:45:23 -04:00
Bianca Severino
666dc22bd0 Merge pull request #28085 from edx/bseverino/proctoring-course-overview
[MST-864] Add proctoring fields to course overview
2021-07-06 12:03:15 -04:00
Kyle McCormick
d86aa824c1 revert: feat: add & expose courseware.use_learning_sequences_api flag (#28054)
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
2021-07-06 11:34:40 -04:00
Bianca Severino
e1738b71ed feat: add proctoring fields to course overview 2021-07-02 14:26:48 -04:00
Manjinder Singh
9b25e2d3da refactor: noop migration for testing (#28078)
This is a noop migration for testing changes
to the deployment pipeline.
2021-07-01 14:28:00 -04:00
Robert Raposa
fdd057b2ad refactor: noop migration for testing (#28052)
This is a noop migration for testing changes
to the deployment pipeline.
2021-06-30 14:49:10 -04:00
Zaman Afzal
843e9ba29b ENT4083: Removed ENABLE_MULTIPLE_USER_ENTERPRISES_FEATURE waffle switch (#28057) 2021-06-30 13:58:11 +05:00
AsadAzam
7212c74713 fix: remove edx-next as a discussion provider (#28059) 2021-06-30 11:08:37 +05:00
Michael Terry
c62626227a fix: jump_to should redirect to first unit on invalid key
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
2021-06-28 15:43:12 -04:00
AsadAzam
f9082a082e fix: re-order the discussion features (#28046) 2021-06-28 19:13:14 +05:00
Albert (AJ) St. Aubin
b23169560f fix: Corrects issue with refund logic and certificates.
[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.
2021-06-28 09:20:00 -04:00
SaadYousaf
16972b4991 test: add tests to test override_legacy_discussion_settings flag with different roles 2021-06-28 11:54:17 +05:00
SaadYousaf
608f1994b7 refactor: move waffle flag calculation to utils file and other updates 2021-06-28 11:54:16 +05:00
SaadYousaf
039a816e57 refactor: move pages_and_resources_mfe WaffleFlag to use in both LMS and Studio 2021-06-28 11:54:16 +05:00
SaadYousaf
09c8ef931e feat: Add CourseWaffleFlag for overriding course discussion settings for legacy experience. 2021-06-28 11:54:16 +05:00
Kyle McCormick
78f1e2b3bd feat: add & expose courseware.use_learning_sequences_api flag (#27993)
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
2021-06-25 11:19:28 -04:00
Julia Eskew
a9b534e10b fix: Use a "through" model for the ManyToManyField fields in CourseSection
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.
2021-06-24 12:17:54 -04:00
Kshitij Sobti
2e416234bc docs: ADR for new course apps API [BD-38] [TNL-8002] [BB-3964] (#27193)
* 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
2021-06-24 11:25:14 +05:00
Diana Huang
29548459fa refactor: Remove PyContracts usage. (#27887)
* refactor: Remove PyContracts usage.

We have not used PyContracts in a while and it is overhead we don't
need in edx-platform.

https://openedx.atlassian.net/browse/DEPR-147

* chore: Updating Python Requirements (#28018)

Co-authored-by: edX requirements bot <49161187+edx-requirements-bot@users.noreply.github.com>
2021-06-23 18:24:06 -04:00
Kshitij Sobti
d2c2fcdefe feat: Course Apps API [BD-38] [TNL-8103] [BB-2716] (#27542)
* 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
2021-06-23 21:51:12 +05:00
Kristin Aoki
456d6c502c fix: Update course preview redirect
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.
2021-06-21 13:36:21 -04:00
Manjinder Singh
5838f191c2 docs: Adding readme for auth_exchange app (#27803)
* docs: Adding readme for auth_exchange app
2021-06-21 12:00:41 -04:00
David Ormsbee
fe6448303d fix: Use learning_sequences to remove bad sequences from outline.
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
2021-06-17 11:13:47 -04:00
Christie Rice
6d703a086e fix: Add missing init files to trigger linting and address quality errors (#27972) 2021-06-16 13:44:20 -04:00
Christie Rice
09d58a4eb8 test: Update course certificate tests before enabling v2 of course certificates globally (#27954)
MICROBA-1082
2021-06-15 10:27:44 -04:00
Mubbshar Anwar
51f1c4cc71 Merge pull request #27932 from edx/mubbshar/VAN-532
fix:Login failed email_or_username
2021-06-15 17:38:21 +05:00
Muhammad Ammar
7d0bf2b3e7 fix: add is_staff permission on endpoint (#27947) 2021-06-14 15:15:34 -04:00
Christie Rice
417b2cc959 fix: Handle missing course overviews (#27849)
MICROBA-1082
2021-06-14 12:57:45 -04:00
Christie Rice
94a1940115 fix: Add missing PII annotation and fix amnesty warnings (#27917) 2021-06-14 09:57:08 -04:00
mubbsharanwar
7b299977b7 fix:Login failed email_or_username
Fix email_or_username null in login failed case.

Fixes: VAN-532
2021-06-14 10:38:40 +05:00
Tim McCormack
c0bed87954 Revert "ENT-4361 | Added user's "id" and "email" as public fields in ACCOUNT_VISIBILITY_CONFIGURATION." (#27942) 2021-06-11 22:53:41 +00:00
Simon Chen
16cffd206f Revert "[FEAT]: Add mem caching to the API to create and retrieve IntegritySignature" (#27936)
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.
2021-06-11 13:59:20 -04:00
Usama Sadiq
2e33565320 fix: fixed the pylint violations causing quality failures (#27934) 2021-06-11 19:49:17 +05:00
Ihor Romaniuk
06c542dfa0 [BD-26] feat: add temporary waffle flag for enabling disabling proctored exams (#27810)
* 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>
2021-06-11 10:04:11 -04:00
Mehak Nasir
baa9fd8831 Merge pull request #27860 from edx/TNL-7832
feat: documentation links added in discussion api
2021-06-11 14:57:42 +05:00
Simon Chen
6d380fc5a2 [FEAT]: Add mem caching to the API to create and retrieve IntegritySignature (#27922)
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
2021-06-10 14:45:06 -04:00
Mehak Nasir
222d898e39 refactor: renaming external keys and improved code review fixes 2021-06-10 21:51:08 +05:00
Julia Eskew
14ec30e018 feat: Make the new courseware MFE the default courseware experience.
- 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
2021-06-10 12:21:24 -04:00
Adeel Ehsan
335a0f28de Merge pull request #27661 from edx/aehsan/VAN-434/account_activation_dialogue_box_added
Account activation popup added
2021-06-10 15:20:15 +05:00
adeelehsan
78f1f1916c Account activation popup added
VAN-434
2021-06-10 14:46:49 +05:00
Mehak Nasir
b6f96f25b9 fix: removed google drive link from codebase 2021-06-10 14:17:35 +05:00
Mehak Nasir
d4431455a1 refactor: updated provider map structure and test cases 2021-06-10 12:01:51 +05:00
Bianca Severino
c3c31af329 Merge pull request #27898 from edx/bseverino/integrity-signature-flag-fix
fix: convert integrity signature waffle flag to CourseWaffleFlag
2021-06-09 14:01:54 -04:00
Bianca Severino
58d5b29f19 fix: convert integrity signature waffle flag to CourseWaffleFlag 2021-06-09 13:19:17 -04:00
Matt Hughes
8023a09191 fix: deleted courses do not break program details page
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
2021-06-09 10:58:00 -04:00
Kyle McCormick
de8859584f Merge pull request #27874 from edx/kdmccormick/xmodule-no-cms
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.
2021-06-09 09:15:31 -04:00
alangsto
8c205e5c0e fix: add created and modified fields to integrity signature admin (#27882)
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.
2021-06-08 12:15:37 -04:00
Simon Chen
a284b9704c [Fix]: CR-3731 correct the spelling of the error message on password reset (#27883) 2021-06-08 11:33:37 -04:00
Kyle McCormick
709db42835 refactor: de-index courses in contentstore, not course_overviews
This is a minor refactoring in order to remove
a code dependency of ./opendedx on ./cms
2021-06-08 10:46:52 -04:00