This completes the work started in https://github.com/edx/edx-platform/pull/19453
to use the LMS login and registration for Studio, rather than Studio
providing its own implementation.
LMS login/registration are being used for the following reasons:
1. LMS logistration properly handles all SSO integrations.
2. A single logistration is simpler to maintain and understand.
3. Allows Studio to work more like all other IDAs that use LMS
logistration.
The original switch to use LMS logistration for Studio also added the
toggle `DISABLE_STUDIO_SSO_OVER_LMS` to provide the community some
additional time for switching. This commit removes this toggle, which
at this point means all deployments will use the LMS logistration.
This change requires sharing cookies across LMS and Studio. Should that
prove to be a problem for certain Open edX instances, there are
discussions of possible alternative solutions.
See https://github.com/edx/edx-platform/pull/19845#issuecomment-559154256
Detailed changes:
* Fix some Studio links that still went to old Studio signin and signup.
* Remove DISABLE_STUDIO_SSO_OVER_LMS feature toggle.
* Remove old studio signin and signup pages and templates.
* Fix url name "login", which had different meanings for Studio and LMS.
* Use the following settings: LOGIN_URL, FRONTEND_LOGIN_URL,
FRONTEND_LOGOUT_URL, and FRONTEND_REGISTER_URL.
* Redirect /signin and /signup to the LMS logistration.
* Add custom metric `uses_pattern_library`.
* Add custom metric `student_activate_account`.
* Add Django Settings to allow /signin, /signup, and /login_post to be
disabled once ready.
This work also relates to ARCH-218 and DEPR-6.
ARCH-1253
The _id comes back as a dict and it's in the wrong order compared to the
dict stored in mongo. This results in lookups for deletion failing when
we use the '_id' as the lookup key.
Luckily the delete function also takes the asset_key as a valid key to
delete by so we just use that instead.
Some of the tests are failing because NullTranslations object is
behaving differently with py2 and py3.With py2, it has 'ugettext'
attribute but with py3 it doesn't have.To make it compliant with
both versions modifications in the tests have been added so that
build will not fail.
PROD-663
Some of the tests are failing because DjangoTranslation object is
behaving differently with py2 and py3.With py2, it has 'ugettext'
attribute but with py3 it doesn't have.To make it compliant with
both versions modifications in the tests have been added so that
build will not fail.
PROD-664
ENABLE_MKTG_SITE has been serving double duty to both indicate that
an Open edX installation is using a Drupal marketing site AND
is using the Publisher workflow tool for managing course metadata.
But now that publisher-frontend is available and the Publisher
feature is no longer tied to the marketing site, we want to tease
apart those two concerns. Hence ENABLE_PUBLISHER.
Only really used so far in Studio, to control which fields are
shown (if using Publisher, some fields are only editable in
Publisher).
Upon rerun creation from publisher course:organization link
was not creating, due to which org logo was not appearing on
course certificates.
Fixed by creating course:org link upon rerun.
PROD-125
Push notifications was only ever setup to connect to Parse.com a service
that has been discontinued. Since we haven't replaced the functionality
for a few years now, remove this dead code.
In cms/templates/js/course_info_update.underscore we're allowing content
to not be escaped because this is by design according to the tests.
Long term there should be a better fix for this but for now this is
intended behavior.
author aarif <mraarif@outlook.com> 1562661182 +0500
committer root <root@lms.devstack.edx> 1563270070 +0000
ran python-modernize and isort on files mentioned in INCR-327
changes made to comply with pylint
changes made to comply with pylint and pass failing test
changes made to comply with pylint