Commit Graph

9290 Commits

Author SHA1 Message Date
Awais Jibran
529a805c0c Fixing dates serialization in course import (#27137) 2021-03-29 13:43:01 +05:00
Usama Sadiq
3e6b3e41f8 refactor: remove unused imports (#27084) 2021-03-24 17:55:04 +05:00
Awais Jibran
49296005db Adding some minor changes to logs (#27127) 2021-03-24 17:25:04 +05:00
Azan Bin Zahid
b5e9c300f8 Merge pull request #27104 from edx/azan/PROD-2204
disbale xsslint
2021-03-24 13:00:25 +05:00
stvn
a0003016b2 Merge PR #26750 colin-fredericks/jsinput-allow-downloads
* Commits:
  feat(jsinput): Allow JSInput problems to create downloads
2021-03-23 10:20:57 -07:00
Awais Jibran
0e4571a5e5 Do not monitor if asset file is not present (#27106) 2021-03-23 01:26:46 +05:00
Azan Bin Zahid
ca6914c1f2 fix: move xss-lint disable comment to correct place 2021-03-22 21:20:26 +05:00
Ahtisham Shahid
da30f24108 Fixed Html escaping in course name in API (#27103)
* Fixed Html escaping in course name in API
2021-03-22 19:52:34 +05:00
Awais Jibran
5f773d326d Add missing import logs. (#27066) 2021-03-22 15:28:13 +05:00
Awais Jibran
c377d87c54 Throw an error message if the assertion fails (#27063) 2021-03-19 12:23:26 +05:00
Awais Jibran
dd3a0bd939 Add missing import logs. (#27056) 2021-03-18 19:57:18 +05:00
AsadAzam
1593b40702 Improved logging for import (#27024)
* Improved logging for import

* Refactored code

* Refactored code

* Refactored code

* Refactored code

* Refactored code

* refactored code

* Refactored code

* Updating log

Co-authored-by: Awais Jibran <awaisdar001@gmail.com>
2021-03-18 12:40:38 +05:00
jawad khan
7d4f192bcb Learner 7611 - Make URLs of all video encodings available in Blocks API (#26701)
* LEARNER-7611
Get all quality video urls in blocks api
* moved video profiles from blocks api to video_module
2021-03-17 13:11:34 +05:00
Ahtisham Shahid
66a62b1670 Fixed rendering issue in course title (#27003) 2021-03-16 18:43:29 +05:00
Kyle McCormick
8813a61da2 feat!: remove SemanticSectionDescriptor, the final XModule (#26990)
A "section" tag in an OLX upload used to map to the
SemanticSectionDescriptor, which translated it into a Sequence
("sequential" tag). This is both obscure and confusing, since it uses
language that predates Studio. Back in the LMS prototype days,
"section" was inconsistently used to be interchangeable with "sequence"
and "sequential", and what Studio today calls a "section" was called a
"chapter". Bits of this legacy terminology are still around in the
courseware rendering code.

The upshot is that if you make an OLX tag "section" before this commit,
it would not map to what we call a "Section" in all our documentation,
but to a "Subsection"; furthermore, if that <section> only had one child
element, the node would be replaced with its singular child, removing
the <section> node from the course tree entirely.

The fact that you can make a "section" OLX tag
at all is nowhere in our documentation because courses haven't been
written that way since late 2011 or early 2012.

SemanticSectionDescriptor came up as part of the XModule ->
XBlock conversion efforts as a legacy XModule that isn't worth
converting. With the removal of this class, all XBlocks
in edx-platform are "pure" XBlocks, ending our reliance
on the XModule-to-XBlock shimming infrastructure.

This commit also removes the process_includes decorator, which was only
used for "section" tags. This does NOT delete the ProblemBlock-specific
<include> tag, which is still supported (if obscure).

There is a chance that through tribal knowledge or copy-paste, some
section tags survive in the wild of old edX courses. It's difficult for
us to assess because by its nature, this tag doesn't just say
"section", but instead actually does the mutation on import so it's
stored as "sequential" in the modulestore–therefore things like
CourseGraph can't detect it.
The fix for any such XML-authored courses is:
* For instances of <section> that wrap a single child node,
  replace the <section> node in favor of its child node.
* For instances of <section> that wrap a sequence of children,
  substitute <section> with <sequential>
Note that "<section>" is a valid HTML tag
type and so may show up in any component that can contain HTML and is
unrelated to the course structure OLX tag alias "<section>" that this
commit removes.

DEPR-124
2021-03-15 09:04:23 -04:00
Usman Khalid
23d1e5b654 Remove unused RawDescriptor and EmptyDataRawDescriptor. 2021-03-11 22:20:33 +05:00
Usman Khalid
78cd8be24d XMLModuleStore should use HiddenDescriptor instead of RawDescriptor.
In https://github.com/edx/edx-platform/pull/25955 `HiddenDescriptor`
(which was a subclass of `RawDescriptor` with a custom `student_view()`)
was converted to an XBlock. It is used as the `default_class` by the
`CachingDescriptorSystem` classes. However `RawDescriptor` is still
being used by `XMLModuleStore`. This has been replaced by
`HiddenDescriptor` as well.
2021-03-11 22:20:33 +05:00
Usman Khalid
fb02353719 Convert TranslateCustomTagDescriptor to TranslateCustomTagBlock. 2021-03-11 22:20:33 +05:00
Usman Khalid
556ef4cb39 Created CustomTagTemplateBlock to use with CustomTagBlock instead of RawDescriptor. 2021-03-11 22:20:33 +05:00
Kyle McCormick
5557194af1 revert: BOM-2378 (B) : pyupgrade in common/lib (#26943)
Reverts #26731

The code in common/lib/capa/capa/safe_exec needs
to remain Python 3.5-compatible, since edx-sandbox
(ie codejail) is still running Python 3.5.
2021-03-10 15:01:09 -05:00
Jeff Witt
ac4c1c37b7 feat: Allow HTML video player to use 2x playback speed
LEARNER-8247

Co-Authored-By: Sarina Canelake <sarina@edx.org>
2021-03-10 09:37:35 -05:00
M. Zulqarnain
b4614d75f0 BOM-2378 (C) : pyupgrade in common/lib/xmodule (#26736)
* refactor: pyupgrade in common/lib/xmodule

Co-authored-by: Usama Sadiq <usama.sadiq@arbisoft.com>
2021-03-10 17:56:39 +05:00
M. Zulqarnain
8e8420dd46 BOM-2378 (B) : pyupgrade in common/lib (#26731)
* refactor: pyupgrade on common/lib

Co-authored-by: Usama Sadiq <usama.sadiq@arbisoft.com>
2021-03-10 17:56:24 +05:00
M. Zulqarnain
deb7f5b026 refactor: pyupgrade in common/lib/xmodule (#26780) 2021-03-10 17:56:07 +05:00
M. Zulqarnain
8aec103447 refactor: pyupgrade in common/lib/xmodule (#26781) 2021-03-10 17:55:49 +05:00
Usman Khalid
e624a8f4ac Convert CustomTagModule to CustomTagBlock. 2021-03-09 09:27:43 -05:00
Usman Khalid
48290cf837 Convert PollModule to PollBlock. 2021-03-09 09:27:43 -05:00
Kyle McCormick
9aefd6f986 style: django-not-configured is not a sensible lint-amnesty value (#26862)
django-not-configured is an error raised by pylint (with
the pylint-django plugin) when it's not correctly configured.

We should not be applying lint amnesty for such a violation.
2021-03-05 08:11:58 -05:00
Jawayria
c5e5b307b5 Merge pull request #26507 from edx/jawayria/bom-2351-6
BOM-2351: Removed unused imports from common/lib/xmodule
2021-03-04 20:36:46 +05:00
Usman Khalid
0e7664fbce test: Fix failing pytest asserts in GradesheetTest.test_weighted_grading. 2021-03-03 18:49:01 +05:00
Usman Khalid
8a8dbee340 test: Fix assertstore and modulestore tests failing because of missing equality functions.
https://github.com/edx/edx-platform/pull/26530 updated the tests to use pytest
assertions instead of unittest assertionss. However, some tests depended on custom
equality functions being set up in the test classes. These tests have been updated
to explicitly do the needed comparisons.
2021-03-03 18:49:01 +05:00
Usman Khalid
f35eed4e4c test: Fix test_capa_module.py::ProblemBlockTest::test_demand_hint_logging. 2021-03-03 16:39:34 +05:00
Jawayria
097613e8b9 BOM-2351: Removed unused imports from common/lib/xmodule 2021-03-03 14:33:54 +05:00
Usman Khalid
7441702ade test: The exception on the pytest ExceptionInfo object can be accessed on the value attribute. 2021-03-03 01:03:36 +05:00
Usman Khalid
1beb4f38a1 test: Remove the invalid pylint message from common/lib/pytest.ini
This auto-added pylint message is preventing tests in common/lib from running.
2021-03-02 23:55:48 +05:00
Usman Khalid
dd96a2aa72 Convert Course, Section and Sequence XModules to XBlocks. (#25965) 2021-03-02 10:29:33 -05:00
Jawayria
9e31096ec5 Merge pull request #26505 from edx/jawayria/bom-2351-5
BOM-2351: Removed unused imports from common/lib/{capa, safe_lxml, sy…
2021-03-02 13:29:10 +05:00
Colin-Fredericks
623cbf8924 feat(jsinput): Allow JSInput problems to create downloads 2021-02-25 16:45:04 -05:00
usamasadiq
96f0915b0f Fixed new pylint warnings.
use generator in any/all()
disable not-callable warnings
disable no-member warnings
Suppressed smaller pylint warnings
Pin edx-proctoring==3.5.0
2021-02-22 16:36:53 +05:00
Maarten
469faaa62d Only add the scrollbar when the width of the screen is small enough (xs) to highlight the whole sequence-nav item (#26405) 2021-02-19 16:11:25 -05:00
Aarif
cce5c9ef1a replaced unittest assertions pytest assertions (#26530) 2021-02-19 12:25:51 +05:00
Ali Akbar
096bfe95dc Merge pull request #223 from edx/IM/security-fixes-12
Incident Management Security Fixes 12
2021-02-17 01:31:49 +05:00
Usman Khalid
62ed654b31 Convert LTIModule into LTIBlock. (#25713) 2021-02-16 09:09:13 -05:00
Jawayria
4fc7b2f640 BOM-2351: Removed unused imports from common/lib/{capa, safe_lxml, symmath, conftest.py} 2021-02-15 13:21:19 +05:00
Carla Duarte
8d2d78dc61 AA-650: block deprecated keys from course home MFE 2021-02-08 13:00:36 -05:00
Ali-D-Akbar
f87507bdfa PROD-2253 2021-02-08 23:00:17 +05:00
Usama Sadiq
1bb06669e3 Merge branch 'master' into usamasadiq/bom-2312-pylint-amnesty-common-lib 2021-02-08 18:26:15 +05:00
Usama Sadiq
90666a6231 Merge pull request #26311 from edx/usamasadiq/bom-2305-pylint-amnesty
Applied pylint-amnesty
2021-02-08 18:23:34 +05:00
usamasadiq
1175838fa5 fix pep8 warnings 2021-02-08 16:08:01 +05:00
usamasadiq
7bbde8f0f5 Applied pylint-amnesty 2021-02-08 13:00:22 +05:00