The length of `purpose` in `StagedContent` is 64. The previous code used the legacy content key. So if the library had a very long key, an error occurred. The new code uses the `pk` instead of the `key`
This commit migrates the data calculation logic for the GradeSummary
table, which was previously in the frontend-app-learning.
This commit also introduces a new visibility option for assignment
scores: “Never show individual assessment results, but show overall
assessment results after the due date.”
With this option, learners cannot see question-level correctness or
scores at any time. However, once the due date has passed, they can
view their overall score in the total grades section on the Progress
page.
These two changes are coupled with each other because it compromises
the integrity of this data to do the score hiding logic on the front
end.
The corresponding frontend PR is: openedx/frontend-app-learning#1797
Adds a library restore endpoint to restore a learning package from a
backup zip archive (/api/libraries/v2/restore/). The learning package
can then be used to create a content library.
If ENABLE_MKTG_SITE is True, MKTG_URLS['ROOT'] must be set. However if
it is set to the same value as the LMS_ROOT_URL (which points to this
view), you can end up in an infinite redirect loop. If the two URLs do
match, don't redirect, just fall through to the content that this page
would have responded with instead.
The 'url' field on the GET /api/libraries/v2/{library_id}/backup/?task_id={task_id}
endpoint was returning realtive paths when the file was stored on the default
FileSystemStorage backend, which makes it inconsistent with other storage
backends and semantically incorrect.
This commit addresses this making sure it always returns an absolute url.
- `handle_update_xblock_upstream_link` is called asynchronously with celery. In `update_upstream_downstream_link_handler`, the xblock has the updated version, but when calling `handle_update_xblock_upstream_link` inside Celery, the xblock is outdated in a previous version, which is why the error occurs. This happens because `on_commit_changes_to` is executed before the MySQL transaction ends.
- Added `ImmediateOnCommitMixin` to be used in tests that need to call `on_commit_changes_to`. See https://github.com/openedx/edx-platform/pull/37485#issuecomment-3412979170 for more info
This check was previously only running on PRs to master, which makes it annoying to stack PRs and have all the checks run. Update it so that the check runs on all PRs and on pushes to master.
The assets page and related tests and settings flags will be removed.
They have been replaced with a new implementation in the
frontend-app-authoring MFE.
BREAKING CHANGE: The legacy_studio.files_uploads flag has been removed
and will no longer allow operators to fall back to the legacy files and
uploads view. The new MFE version is now the only available veiew.
The ContentLibraryMetadata used to hold a version field that was meant
to represent the version of the library as a whole. This is a holdover
from v1 libraries, where all changes to the library resulted in a new
version of the content, and that version indicator was used by courses
to know whether or not an update was available.
This maps poorly to Learning Core backed libraries for a number of
reasons:
1. LC-backed libraries have Draft and Published branches, meaning that
a global "version" may be ambiguous.
2. LC-backed libraries have things like tagging and collections, where
modifications are explicitly *not* versioned at all, and do not show
up in either the publish log or the draft change log.
3. Courses that borrow content from LC-backed libraries track
versioning at the level of the individual thing being borrowed, e.g.
a single Component. This is in keeping with the goal to have very
large libraries with many small bits of content to search and use.
This commit removes the notion of a Library-global version entirely for
v2 (LC-backed) libraries. This does not affect legacy v1 libraries that
are backed by ModuleStore.
The behavior of the MariaDB backend has changed behavior for UUIDField
from a `CharField(32)` to an actual `uuid` type. This is not converted
automatically, which results in all writes to the affected columns to
error with a message about the data being too long. This is because the
actual tring being written is a UUID with the `-` included, resulting in
a 36 character value which can't be inserted into a 32 character column.
The removed tests either needed to check things on the outline page
which makes them not relevant tests, or they just needed data from the
course_handler which they can get from json now.
The tests were testing a set of menu items that were specifically
available on the old course_outline page. Since the page is never
rendered we don't need to test to see if those header items are actually
rendered.
As we finish the rest of the studio frontend cleanup, the header itself
should be removed but just removing these tests since they relied on
conditional bits of the header for when it was showing a course outline.
This page has been replaced with an equivalent page in the authoring MFE
which has been on by default since Teak. This change removes the
ability to fallback to the old page using waffle flags.
BREAKING CHANGE: The `legacy_studio.course_outline` waffle flag will be removed
and the code will behave as if it's always set to `False`. Preventing
you from falling back to the old Course Outline page.
* feat: show item bank ui for migrated legacy library content
* feat: migrate legacy content block to item bank block on view in studio
* fix: duplicate and copy issues
* refactor: migration location and add tests
* fix: lint issues
* fix: item bank and library content children view add button functionality
Newly added blocks from library in children view page of item bank block
and migrated library content block were not displayed automatically.
* fix: lint issues
* fix: lint issues
* feat: only migrate if same version of library is migrated
* refactor: migrate block on request
* fix: component reload on migration
* fix: tests
* refactor: comments and message wordings
* refactor: update alert text
* docs: add context
* fix: component links not being created on migrating legacy blocks
* fix: api docs and types
* refactor: use inheritance and specific parent method call
* fix: imports
* fix: api typing
* fix: upstream_version check
* refactor: rename variables
* refactor: parsing entity keys to usage_keys
Python-evaluated problems were failing to render because they were trying to
invoke `course_id.make_asset_key` in order to obtain the asset key of the
custom Python ZIP file. Learning Core assets work differently (no asset keys,
etc.), and, furthermore, we haven't really thought though how and whether we
want to support custom Python ZIPs in libraries.
So, this fix punts on supporting Python ZIP files in libraries for now, but
enables rendering of advanced CAPA problems which don't rely on a ZIP. This
brings us to parity with Legacy Libraries, which didn't support assets at all
and thus didn't support Python ZIPs either.
Fixes: https://github.com/openedx/edx-platform/issues/37447
The url previously pointed to the legacy index.html with the libraries
tab loaded. Now it redirects to the new libraries endpoint in the
authoring MFE.
We had a set of i18n tests that testing basic english is working on a
page that's going away. It's not necessary. And then we have a skipped
test that tests i18n. It would be good to have actual i18n tests and
there are some other ones in this file at the block level that do test
i18n but since this test isn't actually testing anything novel there's
no need to keep it.
This is the page that lists the courses in studio. This has been
replaced by an MFE and the MFE has been on by default since Teak.
BREAKING CHANGE: Setting the `legacy_studio.home` waffle flag will no longer
work. The code will behave as if this is set to false showing the new
studio authoring MFE experience for the course home page.
This has been the default since Teak.