We add a a new Waffle toggle:
* legacy_studio.logged_out_home
Unless enabled, unauthenticated users accessing Studio will now be sent
to the login page, and then redirected to the logged-in Studio home (the
course listing). By the Ulmo release, the Waffle will be removed along
with the howitworks page, and the new redirect-to-login behavior will
become the only available behavior.
The howitworks page is implemented as a legacy frontend, and we are not
seeing enough value in it to justify a rewrite in React. Via the DEPR
process we confirmed that the new behavior is acceptable, or even
preferable, as it removes edX.org-oriented language from the community
release and reduces the number of clicks needed for Studio users to log
in. We add an a new Waffle toggles
Part of: https://github.com/openedx/edx-platform/issues/36269
which is part of: https://github.com/openedx/edx-platform/issues/36275
* fix: studio registration using the LMS SSO
Add the social-core settings:
```
INACTIVE_USER_LOGIN = True
INACTIVE_USER_URL = 'http://localhost:18010'
```
Change the registration link's `next` parameter to trigger SSO login
after the registration.
- Update migration instructions
- Changes regarding redirect URLs and cookie domain are to permit the
site to run on multiple domains.
- Set LOGIN_URL in common so that it can be unset in environment overrides
This bypasses the "redirect to LMS" login/signup code, but does not yet
remove it; removal is covered by DEPR-166 so that this remains a
configuration-only change for now.
There should have no user-visible effect.
ref: ARCHBOM-1890
Modify the existing login api in a way that
it will allow the user to login via username as well.
currently it is only allowing email to log the user in.
VAN-445
Modify the existing login api in a way that
it will allow the user to login via username as well.
currently it is only allowing email to log the user in.
VAN-445
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.
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
On our fork at Stanford, we override the template for the login lockout
to provide additional information. This means that the second sentence
here, `Try again later.` does not immediately follow the first in our
rendering. As a result, this test fails for us.
Instead, by checking for the most important part of the message
(the first sentence), we're able to ensure that:
- the user is still locked out
- the lockout message is shown on the template
- the test does not fail unnecessarily
It should help catch unicode encoding problems earlier.
This also updates python-saml dependency to a version that includes a
patch for unicode strings.
By default, disable all caching in tests, to preserve test independence.
In order to enable caching, inherit from CacheSetupMixin, and specify
which cache configuration is needed.
[EV-32]
This is a public, versioned, RESTful API for importing and
exporting full course content. The code was initially ripped from the
existing import/export API in the CMS contentstore djangoapp and wrapped
in Django Rest Framework view classes. It's a new djangoapp in
the openedx directory which is largely an abstraction off the CMS
Import/Export views.
This PR includes configuration changes. Most notably, Studio is
configured to serve the OAuth2 provider alongside the LMS.
This is the initial thread on the code list:
https://groups.google.com/forum/#!msg/edx-code/DmnHWmly25A/ZqjD1zb4o7oJ
And this thread contains another description of the changes:
https://groups.google.com/d/msg/edx-code/6dP9SEKsmqQ/Pvyn8fBDx68J
There are a numerous non-covered lines, all of which are missing
coverage in the CMS API this was ported from. They're mostly error
conditions, such as handling of multipart file upload errors.
When the list is empty in discussion blackout
on studio side it causes the exception on lms
side when we try to access the discussion. We
were expecting the values and try to parse it
in two values start and end date whereas parsing
empty values to two values causing the exception.
Now values will be parse when value exists. Empty
value will be ignored.
TNL-1390