This commit introduces the changes needed for XBlocks in Blockstore to save
their user state into CSM. Before this commit, all student state for Blockstore
blocks was ephemeral (in-process dict store).
Notes:
* The main risk factor of this PR is that it adds non-course keys to the
course_id field in CSM. If any code (like analytics?) reads course keys
directly out of CSM and doesn't have graceful handling for key types it
doesn't recognize, it could cause an issue. With the included changes to
opaque-keys, calling CourseKey.from_string(...) on these values will raise
InvalidKeyError since they're not CourseKeys. (But calling
LearningContextKey.from_string(...) will work for both course and library
keys.)
* This commit introduces a slight regression for the Studio view of XBlocks in
Blockstore content libraries: their state is now lost from request to request.
I have a follow up PR to give them a proper studio-appropriate state store,
but I want to review it separately so it doesn't hold up this PR and we can
test this PR on its own.
The proctoring app assumes that this setting exists and so we get an
attribute error at runtime if it doesn't. In python 2 this was not an
issue but because of the change in how exceptions are handle for getting
attributes, it's a problem in python 3.
The correct thing to do would be to fix this in the proctoring app so
that it checks for the existence of its value before using it but that's
a longer cycle to make/deploy that change so doing this as a stopgap to
get past it.
https://github.com/edx/edx-platform/pull/20645
This introduces:
* A new XBlock runtime that can read and write XBlocks that are persisted using
Blockstore instead of Modulestore. The new runtime is currently isolated so
that it can be tested without risk to the current courseware/runtime.
* Content Libraries v2, which store XBlocks in Blockstore not modulestore
* An API Client for Blockstore
* "Learning Context" plugin API. A learning context is a more abstract concept
than a course; it's a collection of XBlocks that serves some learning purpose.
Fixing quality test
Testsing out a default value for the sake of jenkins tests. will revert
Fix footer test from being flaky
Moving an import statement
ran isort. adding a test. fixing 1 quality issue
Quality cleanups
Attempting more quality fixes
adding back in config variable name for default value
Adding ENTERPRISE_MARKETING_FOOTER_QUERY_PARAMS to common settings
Changing marketing_url logic to only concatenate enterprise url to root if the enterprise url is relative (starts with a /)
quality fixes
The JWT_COOKIES_FLAG was a temporary flag used for rollout of the new
JWT cookies. These are live in Production, so we are removing the flag.
Without this flag, we set JWT cookies during login. However, this
requires an oAuth Client that isn't always available during unit tests.
We introduced a feature flag that is only used for unit tests to
disable setting the JWT cookies. The code explains a bit more why this
solution was selected over adding the oauth client to the database.
ARCH-247
relied on the old configuration values and old way of validating
passwords. Also improved registration page by always showing error
messages rather than hiding them on leaving the field.