Commit Graph

17737 Commits

Author SHA1 Message Date
Dave St.Germain
cfd1e2ae7d Merge pull request #22707 from edx/dcs/sequence-api
Implementation of metadata endpoint for sequence modules
2020-01-15 10:33:18 -05:00
Dave St.Germain
20235bcf56 Added subsection id to gated metadata. 2020-01-14 10:01:07 -05:00
Zulqarnain
93a726ff6b Merge branch 'master' into zulqarnain/BOM-1138 2020-01-14 15:25:20 +05:00
Awais Qureshi
1e572ef539 Merge pull request #22770 from edx/awais786/BOM-1084
BOM-1084
2020-01-14 09:34:58 +05:00
edX cache uploader bot
b4eb64a425 Updating Bokchoy testing database cache (#22833) 2020-01-13 13:03:37 -05:00
Dave St.Germain
507b85ee3d Return sequence metadata from an ajax handler endpoint, to support the new courseware micro-frontend. 2020-01-13 11:26:02 -05:00
Awais Qureshi
a2ab14d756 Bom-1146
Enabling migration test.
2020-01-13 20:27:53 +05:00
Awais Qureshi
8b3b045803 BOM-1084
Bump django-filter.
Rename the name to field-name.
2020-01-13 20:25:44 +05:00
edX cache uploader bot
9ac40c79c3 Updating Bokchoy testing database cache (#22815) 2020-01-13 08:25:07 -05:00
Aarif
d89a1b872d Merge pull request #22713 from edx/BOM-1131
Updated the Mako Loader to remove deprecated methods
2020-01-10 21:34:04 +05:00
edX cache uploader bot
6eefba4e14 Updating Bokchoy testing database cache (#22792) 2020-01-10 09:44:26 -05:00
Awais Qureshi
390bae36e8 Bom-1146
Due to some recent schema changes this test is failing. Temporarily skipping it. Fix it in other PR.
2020-01-10 10:59:45 +05:00
mraarif
ecdf2a3ebd updated the custom Loader to remove deprecated methods 2020-01-10 03:16:29 +05:00
Stu Young
6fa7940792 Add django simple history to student.ManualEnrollmentAudit (#22629)
add django simple history to student.ManualEnrollmentAudit
2020-01-09 16:29:18 -05:00
David Ormsbee
bb271e10e8 Revert "Request cache context processor output."
This reverts commit ad5cc3d5d9.

This was causing middleware errors while processing 404s.
2020-01-09 10:51:42 -05:00
Mahyar Damavand
f1c5981fab Removing deprecated management commands which intended to clear historical data (#21522) 2020-01-08 12:50:34 -05:00
edX cache uploader bot
460a08d3f4 Updating Bokchoy testing database cache (#22762) 2020-01-08 09:41:42 -05:00
edX cache uploader bot
58b6247d6b Updating Bokchoy testing database cache (#22759) 2020-01-08 07:54:57 -05:00
Zulqarnain
cf58da6ee0 Update assertRedirects usage 2020-01-08 14:35:40 +05:00
Usama Sadiq
2de89d6e49 Merge pull request #22732 from edx/usama/bom-1136
BOM-1136
2020-01-08 11:49:04 +05:00
Troy Sankey
1178ad8b8b Rename order in CreditRequirement (3/3)
This stage does the following:

- Includes a migration to delete the old column.
- NO code changes.
2020-01-07 19:17:56 +05:00
usama sadiq
1c52f19f19 Deprecation of the direct assignment to the forward side of a many-to-many set
Changed the direct assignments with the use of set() method.
2020-01-07 14:40:23 +05:00
edX cache uploader bot
02daf89745 Updating Bokchoy testing database cache (#22706) 2020-01-03 15:56:55 -05:00
Ned Batchelder
ae6132c2eb Merge pull request #22693 from cclauss/patch-1
from xmodule.modulestore.exceptions import MultipleLibraryBlocksFound
2020-01-03 13:00:42 -05:00
Troy Sankey
407c8cb076 Rename order in CreditRequirement (2/3)
This stage does the following:

- Includes a data migration to copy the values from old to new field.
- Changes business logic to switch to using new field.
- Deletes all code references of the old field.
2020-01-03 18:07:28 +05:00
Christian Clauss
69f286c90c from xmodule.modulestore.exceptions import MultipleLibraryBlocksFound
Undefined name: __MultipleLibraryBlocksFound__ is raised on line 1096 but is never defined or imported.
2020-01-02 23:49:32 +01:00
Ned Batchelder
471bb41b5b Merge pull request #22680 from edx/nedbat/remove-accepts
Remove unused code
2020-01-02 11:17:13 -05:00
Manjinder Singh
6c69b6d435 Adding code to output pytest warnings. (#22570)
* Added pytest-json-report plugin
	- modifying app-opts in setup.cfg
	- adding hook to all conftest.py files in repo
	- setting report to be saved to test_root/log/warnings.json
	- Writing custom logic to save json report to avoid overwrite if pytest called twice
This was created to allow us to easily parse through test warnings in jenkins
2020-01-02 10:01:52 -05:00
edX cache uploader bot
f4bb9b4b8e Updating Bokchoy testing database cache (#22681) 2020-01-02 09:45:19 -05:00
Ned Batchelder
05700f724e Remove unused code 2020-01-02 07:22:17 -05:00
Zainab Amir
43a06fe385 Fix failing bokchoy test (#22670) 2020-01-02 11:03:01 +05:00
David Ormsbee
ad5cc3d5d9 Request cache context processor output.
In Django template rendering, context processors only run once.
But when we do template rendering through edxmako (which we do for
each and every web fragment/XBlock), we can end up having hundreds
of invocations of templates and run context processors for each
separately. This removes that work.
2019-12-30 16:38:46 -05:00
David Ormsbee
2cb2265ffe Add request caching to reduce ORM queries
This adds request caching to the following places:
* course expiration wrapper (displayed in Units)
* offer banner generation (displayed in Units)
* get_enrollment
* user_by_anonymous_id
* youtube_disabled_for_course

On a sample course with edx-val enabled, this reduced the queries
for a large sequence from 450 to 155.
2019-12-30 16:19:25 -05:00
edX cache uploader bot
e326520c03 Updating Bokchoy testing database cache (#22655) 2019-12-30 15:57:43 -05:00
Feanil Patel
046feb0cf0 Merge pull request #22649 from edx/feanil/fix_pep8
Fix all E303 pep8 errors.
2019-12-30 13:32:26 -05:00
Feanil Patel
6e3fe00fff Fix all E303 pep8 errors. 2019-12-30 12:25:38 -05:00
Feanil Patel
2df8b8226b Merge pull request #22643 from edx/feanil/2to3_asserts
Run `2to3 -f asserts . -w` on edx-platform.
2019-12-30 12:13:42 -05:00
Feanil Patel
39d3a7ca17 Fix pep8 issues caused by the fixer. 2019-12-30 11:42:04 -05:00
Feanil Patel
61e1eda20d Merge pull request #22644 from edx/feanil/2to3_imports
Run `2to3 -f future . -w`
2019-12-30 11:21:05 -05:00
Feanil Patel
9cf2f9f298 Run 2to3 -f future . -w
This will remove imports from __future__ that are no longer needed.

https://docs.python.org/3.5/library/2to3.html#2to3fixer-future
2019-12-30 10:35:30 -05:00
Feanil Patel
70294b0ad2 Run 2to3 -f asserts . -w on edx-platform.
https://docs.python.org/3.5/library/2to3.html#2to3fixer-asserts
2019-12-30 10:22:19 -05:00
edX cache uploader bot
a6f374c90b Updating Bokchoy testing database cache (#22640) 2019-12-30 09:55:34 -05:00
Jeremy Bowman
63574e12b8 Remove pytest version constraint (#22626)
Fix the issue that was preventing us from upgrading pytest.  pytest does some manipulation of test packages that prevents `pkg_resources` from loading resources from them, but used to contain a workaround for the problem.  That workaround was [removed](https://github.com/pytest-dev/pytest/issues/5392) in 4.6.0 as a performance enhancement when pytest switched from `pkg_resources` to `importlib-metadata` for its own entrypoint handling.  This tripped up one of our test modules which defined classes that loaded templates from inside a test package.  Moving these resources to the parent package fixes the problem.

More and more, `pkg_resources` is being abandoned in favor of `importlib-metadata` and `importlib_resources` as they have a simpler design with much better performance.  However, `importlib_resources` doesn't support loading files from any directory which isn't itself a Python package (and doesn't allow direct use of paths including directories within the package).  Jinja2 chose a [different approach](https://github.com/pallets/jinja/pull/1082) that we may want to emulate in our resource handling.

Also fixed usage of a removed `pytest.raises()` parameter and a bug in our configuration of the `common/lib` tests that became a problem after the upgrade.
2019-12-30 09:10:57 -05:00
Awais Qureshi
c7c6242a0e Merge pull request #22617 from edx/awais786/BOM-1124
BOM-1124
2019-12-30 15:09:27 +05:00
Zainab Amir
257c635a68 Fix Targeted Feedback HTML (#22606)
etree.tostring returns bytes instead of string which when converted
back to XML, to be rendered as etree element, presents stray
characters.

PROD-1116
2019-12-30 15:06:02 +05:00
Awais Qureshi
804a84f9cf BOM-1124
Direct assignment to the forward side of a many-to-many set is deprecated Fixing this issue.
2019-12-28 00:04:15 +05:00
Feanil Patel
59808c82f1 Merge pull request #22611 from edx/feanil/fix_mathjax_bug
Don't try to typset mathjax if Hub has not loaded.
2019-12-27 11:22:22 -05:00
edX cache uploader bot
1cbe81f747 Updating Bokchoy testing database cache (#22614) 2019-12-27 09:19:10 -05:00
edX cache uploader bot
fe1f69741e Updating Bokchoy testing database cache (#22608) 2019-12-26 16:39:55 -05:00
Feanil Patel
ff40369990 Don't try to typset mathjax if Hub has not loaded.
In our tests there are times when Mathjax has been initialized but
Hub is still undefied.  In this case don't queue up typesetting.
2019-12-26 16:13:58 -05:00