Commit Graph

9502 Commits

Author SHA1 Message Date
Muhammad Soban Javed
4463ee751d Revert "refactor: move common/lib/capa/capa to xmodule/capa" (#30762) 2022-07-21 18:22:15 +05:00
Soban Javed
9eba9f983a refactor!: move common/lib/capa/capa to xmodule/capa
As part of dissolving our sub-projects in edx-platform, we are moving this package under the xmodule directory.
We have fixed all the occurences of import of this package and also fixed all documents related references.
This might break your platform if you have any reference of `import capa` or `from capa import` in your codebase or in any Xblock.

Ref: https://openedx.atlassian.net/browse/BOM-2582
2022-07-19 12:20:04 +05:00
Sagirov Evgeniy
dccb463103 FC-0001: Remove edx-jsme, Molecular Structure Problem type (#30321)
* feat: Remove edx-jsme, Molecular Structure Problem type

* feat: remove common/static/js/capa/jsme and common/static/js/capa/jsmolcalc
2022-07-06 15:51:58 -04:00
Muhammad Umar Khan
a389a9ff10 Revert "Revert "refactor: move xmodule folder to root"" 2022-06-20 18:20:06 +05:00
Muhammad Umar Khan
d890f06507 Revert "refactor: move xmodule folder to root" 2022-06-20 16:03:48 +05:00
M Umar Khan
a91df0c40f refactor: move xmodule folder to root
- Moving xmodule folder to root as we're dissolving sub-projects of common folder in edx-platform
    - More info: https://openedx.atlassian.net/browse/BOM-2579
- -e common/lib/xmodule has been removed from the requirements as xmodule has itself become the part of edx-platform and not being installed through requirements
- The test files common/lib/xmodule/test_files/ have been removed as they are not being used anymore
2022-06-20 14:33:45 +05:00
Maria Grimaldi
19ed61b6c2 fix: add () to print statement so template works in newer versions 2022-06-15 08:29:16 -07:00
Feanil Patel
b9131ac1af Merge pull request #30299 from raccoongang/depr/remove-course-info
FC-0001: Remove legacy course info page & related code
2022-06-13 08:23:25 -04:00
Arunmozhi
ba8e98c710 refactor: move noauth rebind ModuleSystem argument to service (#30320)
This removes the `rebind_noauth_module_to_user` argument from the
ModuleSystem constructor and moves it to a separate service called
"rebinder" in the class `RebindModuleService`. This is used in the
LTI module to bind calls received by its noauth endpoint to bind
the module the real_user.
2022-06-08 20:26:59 +02:00
Arunmozhi
aedcd7910d refactor: deprecate hostname attribute from ModuleSystem (#30308)
The hostname constructor argument of the XModule ModuleSystem is deprecated
in favour of directly accessing the LMS_BASE value from django.conf.settings.
2022-06-08 19:49:58 +02:00
Demid
8886f29e52 refactor: remove debug property from ModuleSystem (#30450)
This also:
1. Removes this property from XBlock runtime shims.
2. Updates the minimum required version of the LTI Consumer XBlock.
2022-06-08 18:59:45 +02:00
Arunmozhi
c54d8a81bf refactor: deprecate node_path attribute of ModuleSystem (#30447)
The node_path attribute & constructor argument of the ModuleSystem is
deprecated without any replacement service or fallback as there doesn't
seem to be any core blocks using it.

It also removes the references to node_path from the LMS settings, the
LoncapaModuleSystem and the XBlock runtime shim.

Co-authored-by: Agrendalath <piotr@surowiec.it>
2022-06-08 18:06:59 +02:00
connorhaugh
c9dce91b9a feat: studio redirect to new editors (#30523) 2022-06-07 16:30:40 -04:00
Jeremy Ristau
d253503099 Merge pull request #29728 from open-craft/tecoholic/add_reset_to_randomized_content_block
feat: add reset option to the Randomized Content Block
2022-06-06 12:34:15 -04:00
Sagirov Eugeniy
92ca176fde refactor: Remove legacy course info page & related code 2022-06-05 19:00:05 +03:00
Awais Qureshi
02e29168b2 feat!: Removing sandbox folder from platform and installing it from p… (#30402)
* feat!: common/lib/sandbox-packages folder moved to a new library.
2022-06-01 16:02:13 +05:00
Usama Sadiq
8053b7d90c refactor: replace coursekey.course with coursekey.library (#30398) 2022-05-27 15:55:12 +05:00
Kyle McCormick
25df9ca420 refactor: make safe_lxml an ordinary folder in openedx/core/lib (#25689) 2022-05-24 15:35:23 +05:00
Arunmozhi
2b39da69b9 feat: add reset option to Randomized Content Block
This makes the reset button to refresh the contents of a Randomized
Content Block (RCB) without reloading the full page by fetching a new
set of problems in the "reset" response and replacing the DOM contents.

The reset button returns the student view as a string and the client
uses the HtmlUtils package to replace the contents and reinitializes the
XBlock.

This allows students to use the RCB as a flash card system.

Co-authored-by: tinumide <tinuade@opencraft.com>
2022-05-23 14:54:19 +02:00
Demid
a4ec4c1b8e refactor: Delete XModule classes (#30262)
Removes XModule, XModuleDescriptor, ProxyAttribute classes and their usages.
2022-05-10 19:09:11 +02:00
Agrendalath
0ef57eb136 fix: do not index solutions in CAPA blocks
Most tags that could contain solutions or hints were already being removed,
but the regex did not include the case when they contained attributes.
2022-05-10 19:04:29 +02:00
Eugene Dyudyunov
8bd43207ca refactor!: switch from LegacyWaffle* to modern waffles (#30330)
This is a first stage for removing the LegacyWaffle* classes.

LegacyWaffleFlag usage replaced with WaffleFlag;
LegacyWaffleSwitche usage replaced with WaffleSwitch;
New CourseWaffleFlag added to the temporary module __future__ as FutureCourseWaffleFlag;
Updated all the imports to use CourseWaffleFlag from the __future__ module;

BREAKING CHANGE: A number of toggle related constants (e.g. ENABLE_ACCESSIBILITY_POLICY_PAGE)
changed types. They were strings, and are now toggle instances (e.g. WaffleSwitch). Although the entire
refactor should be self-contained in edx-platform, if any plugins or dependencies were directly
using these constants, they will break. If this is the case, try to find a better publicized way of
exposing those toggles.
2022-05-05 12:03:10 -04:00
Kaustav Banerjee
702866b225 feat: delete XModuleDescriptorToXBlockMixin (#29927)
This:
1. Deletes XModuleDescriptorToXBlockMixin
2. Deletes `metadata_traslations` and `_translate()` from `XmlParserMixin`,
    and all related implementations.
3. Removes translations of deprecated OLX attributes during import/export:
    <old_attr> : <new_attr>
    - 'slug' : 'url_name'
    - 'name' : 'display_name'
    - 'id' : 'discussion_id' (Discussion XBlock)
    - 'for' : 'discussion_target' (Discussion XBlock)
    - 'attempts' : 'max_attempts' (CAPA)
2022-04-21 16:15:00 +01:00
Jillian Vogel
d0935d467c fix: fixes bug with HTML blocks in studio_view
Rendering asset URLs requires HTML blocks to be associated with a course key.
This change allows HTML blocks to be associated with libraries and still
render without error.
2022-04-21 09:39:59 +01:00
Usama Sadiq
1df2c691db fix: bump bleach and django-wiki versions (#30263) 2022-04-20 10:39:50 +05:00
Demid
16fa97dde4 feat: deprecate filestore
This:

1. Removes the `filestore` property from the `ModuleSystem` in favor of
   the `runtime.resources_fs` property.
   In the original code, `filestore` is equal to
   `DescriptorSystem.runtime.resources_fs`. It's safe to replace it with
   `ModuleSystem.runtime.resources_fs` because both runtimes are combined
   using the `CachingDescriptorSystem`. It provides the `resources_fs` property
   that uses the same file storage.

2. Renames `filestore` argument to `resources_fs` in the `LoncapaSystem`
   constructor.

3. Adds the deprecated `filestore` property to the `ModuleSystemShim`
   and `RuntimeShim`.
2022-04-14 14:45:05 +02:00
Maria Grimaldi
550e5b26aa Merge pull request #30050 from eduNEXT/jlc/fix-rtl-studio-problem-editor
fix: fix RTL text in editor of xblock problem.
2022-04-13 13:43:51 -04:00
Sarina Canelake
711f5a1ae6 Merge pull request #30162 from openedx/sarina/ie
docs: Remove IE from supported browsers in Open edX course overviews
2022-04-07 17:02:07 -04:00
muhammad-ammar
735607a752 feat: add an xblock renderer endpoint to serve videos as public having
public access set by course author in studio
2022-04-05 16:42:39 +05:00
alangsto
681c2f1d6c chore: remove IDV references for proctoring and student/instructor display (#30146)
Places where IDV is referenced for blocking proctoring or displaying the IDV status to students and instructors should be removed. This includes the use of the ENABLE_INTEGRITY_SIGNATURE setting, which was used in part to deprecate IDV in those specified places. Other areas where ENABLE_INTEGRITY_SIGNATURE is used (such as for showing/hiding the integrity signature, for the verification deadline, or for certs) shall be left as is due to deprecation concerns.
2022-04-04 08:11:40 -07:00
Sarina Canelake
839dd660e6 docs: Remove IE from supported browsers in Open edX course overviews 2022-03-31 20:23:11 -04:00
Agrendalath
d05e5c639f feat: allow marking Library Content Block as complete on view
edx/edx-platform#24365 has changed the completion mode of these blocks.
Before Koa, it was sufficient to view the block to get a completion checkmark.
Since Koa, all children of the block must be completed.

This adds a toggle to change the completion behavior back to the previous one
so that the user experience can be consistent if needed.
2022-03-22 19:09:50 +01:00
johanv26
f8368e4547 fix: fix RTL text in editor of xblock problem.
(cherry picked from commit 96e903c86c4a0031b21fc564d824a2c02bf98d9c)
2022-03-16 10:56:03 -05:00
zia.fazal@arbisoft.com
e9e74f941f feat: trigger complete_video event when video is marked for completion
Fixed broken tests

fix: fix broken tests

chore: removed whitespace
2022-03-15 12:23:39 -04:00
Kaustav Banerjee
c48c655998 refactor: deprecates replace url related properties from ModuleSystem
Deprecates the following attributes from ModuleSystem:
 * replace_urls
 * replace_course_urls
 * replace_jump_to_id_urls

A new ReplaceURLService is created as replacement with a unified replace_urls method
2022-03-14 09:35:41 -04:00
Dillon Dumesnil
d43ece5dba feat: AA-1205: Add Learning MFE support for Entrance Exams
* Adds entrance exam information to the Course Overview object
    * Enables hiding other tabs since the get_course_tab_list uses
      a Course Overview
    * Enables using the entrance exam helper functions to determine
      if Entrance exams are being used in this course.
* Posts a message when Entrance Exam is passed to parent container for
usage in the Learning MFE
* Overrides the 'title' field of the courseware tab since the Learning MFE
uses that over the 'name' field.
2022-03-14 09:04:45 -04:00
Dillon Dumesnil
61b93d953d feat: Add backfill course tabs management command
Previously, course tabs would only be created once and never try to
update the default tabs again. This leads to an issue if you ever want
to add a new tab. With this command, you can now update the default tabs
for all existing courses and new courses will pick it up upon creation
when CourseTabList.initialize_default is called.
2022-03-11 11:16:18 -05:00
Braden MacDonald
dcb7ef8821 feat: Read course indexes from MySQL, not MongoDB (#29184)
Description
This is a follow up to #29058 and #29413. This is the next step in moving part of the modulestore data (the course indexes / "active versions" table) from MongoDB to MySQL.

There are four steps planned in moving course index data to MySQL:

Step 1: create the tables in MySQL, start writing to MySQL + MongoDB  done
Step 2: migrate all remaining courses to MySQL  done
Step 3: switch reads from MongoDB to MySQL (this PR)
Step 4 (much later, once we know this is working well): stop writing to MongoDB altogether.
Supporting information
OpenCraft Jira ticket: MNG-2557

Status
 Tested with a large Open edX instance is in progress.

Testing instructions
Try making changes in Studio and verify that they work fine.

Deadline
None
2022-03-09 10:21:09 -05:00
connorhaugh
23690712ba fix: capa numerical response with scientic notation (#30010)
I found a potential location for a solution to the numericalinput bug. The problem stemmed from. In the convert markdown -> xml process, here, the checkIsNumeric function rejects the input if stringValue.match(/[a-z]/i) which says: does this value contain any letters, regardless of case? This rejection would cause uses of e and i in answers like the described problem to be string input problems. A simple fix would be to replace that match with regex like '/[a-df-hj-z]/i'.
2022-03-03 16:16:17 -05:00
SaadYousaf
782ee338c9 fix: remove pre tag processing for course import 2022-02-21 16:29:01 +05:00
SaadYousaf
65f7800083 refactor: cleanup investigation logs 2022-02-21 13:28:39 +05:00
Carlos Muniz
37bf73ca50 refactor: Replace videosequence & problemset (#29905)
`videosequence` and `problemset` have been replaced with `sequential`.

`problemset` and `videosequence` are old-but-not-entirely-unused aliases to the `sequential` block type (in Studio-speak, "Subsection").
Since [these block types have been removed from the 6 courses that used them](https://openedx.atlassian.net/browse/DEPR-151?focusedCommentId=588197), this ticket removes the support for the `problemset` and `videosequence` block-types.

For more information, see ticket: [DEPR-151](https://openedx.atlassian.net/browse/DEPR-151)
2022-02-16 10:21:31 -05:00
Bianca Severino
af81b3a609 chore: replace integrity signature flag with django setting 2022-02-15 09:57:00 -05:00
Carlos Muniz
8e8d8404be Carlos muniz/symmath removal unrevert (#29912)
* Revert "Merge pull request #29909 from openedx/revert-29869-Carlos-Muniz/symmath-removal"

This reverts commit 8c0db8ddff, reversing
changes made to 1156c62014.

* fix: Remove misplaced `-e`

`-e` was wrongfully placed in front of `common/lib/sandbox-packages`,
which may have most likely been causing the edxAPP to break.

* fix: Change regex to apply to right dirs

`py38.txt` does not include `common/lib/xmodule` so it doesn't match the
regex. Therefore, it never got its lines in `common/lib/sandbox-packages`
fixed. If we change the regex to match any `common/lib/<packagename>` it
should work correctly.
2022-02-14 10:26:40 -05:00
Michael Terry
e81c4fe49d Merge pull request #29911 from openedx/mikix/more-old-mongo-test-cleanup
test: more Old Mongo removal from tests
2022-02-11 15:10:45 -05:00
Michael Terry
b905de757b test: more Old Mongo removal from tests
Convert more tests from MONGO_AMNESTY to SPLIT modulestores.

This is in preparation for just wholesale denying access to Old
Mongo, so I either converted tests to split or just deleted some
test variants that were Old Mongo specific. (e.g. ddt lines)
2022-02-11 14:50:30 -05:00
Phillip Shiu
6ac1dd688a Revert "Remove symmath from edx-platform" 2022-02-11 10:30:08 -05:00
Carlos Muniz
a01a7ad416 feat: Update openedx-calc==3.0.1
This allows common/lib/capa/capa/responsetypes.py to not have to
change.
2022-02-10 15:06:20 -05:00
Carlos Muniz
675486a174 fix: Correct path to symmath function 2022-02-10 15:06:20 -05:00
Carlos Muniz
18e4c1cec4 refactor: Remove symmath from common/lib 2022-02-10 14:55:22 -05:00