Commit Graph

27 Commits

Author SHA1 Message Date
Usama Sadiq
859df03049 refactor: ran pyupgrade on lms/djangoapps/courseware (#26737) 2021-03-12 12:15:58 +05:00
Usman Khalid
dd96a2aa72 Convert Course, Section and Sequence XModules to XBlocks. (#25965) 2021-03-02 10:29:33 -05:00
Jawayria
03e6a874d0 Applied pylint-amnesty to courseware 2021-02-03 21:56:24 +05:00
M. Zulqarnain
feaf5011c8 BOM-2287 : Pylint amnesty in teams,tests,survey and verify_student (#26305)
* lint amnesty in teams,tests,survey and verify_student
2021-02-03 18:15:03 +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
Ayub khan
af2e7705b1 INCR-434 python3 compatibility 2019-07-16 15:54:54 +05:00
Ned Batchelder
7d964b12db Context managers need to clean up properly
An @contextmanager will raise an exception from its yield statement if
an exception happens in the with-block that uses it.  If the context
manager needs to do clean up, it should do it even if an exception is
raised, so it needs to be done in a finally clause.
2019-04-17 13:14:48 -04:00
Gabe Mulley
009c1f7901 REVE-81: fix errors in drag and drop and ORA2 xblocks
Also fixes REVE-82
2018-11-15 14:29:51 -05:00
Calen Pennington
72f556c1a9 Import courseware module from fully-qualified module name 2018-10-10 15:34:33 -04:00
Robert Raposa
ba4cc62ff8 Retire deprecated RequestCache (Take 2)
ARCH-223
2018-09-08 15:09:28 -04:00
Nimisha Asthagiri
4ca165f690 Revert "ARCH-223: Retire deprecated RequestCache." 2018-08-30 16:33:03 -04:00
Robert Raposa
3df339a56a Retire deprecated RequestCache.
ARCH-223
2018-08-30 08:55:19 -04:00
Qubad786
64555c60c0 Move request_cache to openedx.core.djangoapps 2018-01-26 15:09:25 +05:00
Jeremy Bowman
ca97e946a6 Switch to pytest for unit tests 2017-09-22 16:07:53 -04:00
Andy Armstrong
79acb5c5be Reorder LMS imports using isort 2017-06-11 21:48:06 -04:00
John Eskew
3b57542ab0 Revert "Merge pull request #15170 from edx/jeskew/PLAT_1316_partitions_inheritance"
This reverts commit f97f052591, reversing
changes made to 800bcd8e20.
2017-05-30 12:42:54 -04:00
John Eskew
76389d8678 Run all files touched in inheritance/partition work through isort. 2017-05-25 13:24:08 -04:00
John Eskew
66f3aa5ccf Move fields.py, inheritance.py, and partitions to openedx/core. 2017-05-25 13:24:08 -04:00
Renzo Lucioni
cd9986b662 Override field data within the XBlock runtime
Resolves an issue preventing students in self-paced courses from seeing all available discussion modules. ECOM-3733.
2016-03-18 17:15:00 -04:00
Peter Fogg
786c4456ea Last-accessed courseware on the home page.
ECOM-2806
2016-02-03 13:58:22 -05:00
Peter Fogg
4805946a83 Override due dates in the LMS for self-paced courses. 2015-10-28 14:33:11 -04:00
Calen Pennington
b8e63cbb4d Disable lineage traversal when no providers are specified in OverrideFieldData 2015-06-17 15:26:10 -04:00
Carlos de la Guardia
d56303dd0f Only enable the OverrideFieldData when there are active overrides on a course. 2015-06-17 15:26:10 -04:00
Carlos de la Guardia
9ddee93401 MIT: CCX. Code Quality fixes
add doc strings; fix pep8 warning
address some minor issues brought up by the code review process
2015-04-10 23:30:26 -04:00
Carlos de la Guardia
b3da2a54bb MIT: CCX. Fix issues identified in code review
Original Commit Messages:

use edx's own get_parent method, rather than our own.

add field to unique constraint to avoid MultipleObjectsReturned in case of multiple browser clicks on submit

fix 0011 migration, inherit from TimeStampedField and add composite index (migration only)

fix bug where adding an already registered user to a ccx would cause a crash due to an undefined variable

add assertNumQueries tests to test modules where override field providers are used

remove unnecessary teardown

implement recommended style for checking empty list

import utility methods rather than use duplicate code

added comment explaining date conversion to string for json

add logging for invalid users or emails when enrolling students

add comment about xmodule user state

avoid using get_or_create, which seems to be causing a race condition on schedule change save

relocate badly placed edvent handlers to fix multiple submit problem
2015-04-10 23:30:26 -04:00
Chris Rossi
2b4da4d836 MIT: CCX. Address performance issues.
Use client's session to set POC for test, now that we have the capability to do that.

Use a middleware to set the current POC one time per request, and avoid having to look up the stack for the current request in 'get_current_poc'.

Fetch all overrides for a block at one time.

Speed up the lineage computation by doing some caching.

Unused import.

Get field overrides once per user per block.

Streamline configuration.

Fix poc config tuples
2015-04-10 23:17:38 -04:00
Chris Rossi
3256eb1ff6 Architecture for arbitrary field overrides, field overrides for
individual students, and a reimplementation of the individual due date
feature.

This work introduces an architecture, used with the 'authored_data'
portion of LmsFieldData, which allows arbitrary field overrides to be
made for fields that are part of the course content or settings (Mongo
data).  The basic architecture is extensible by means of writing and
configuring arbitrary field override providers.

One concrete implementation of a field override provider is provided
which allows for overrides to be for individual students.  This provider
is then used as a basis for reimplementing the individual due date
extensions feature as a proof of concept for the design.

One can imagine writing override providers that provide overrides based
on a student's membership in a cohort or other similar idea.  This work
is being done, in fact, to pave the way for the Personal Online Courses
feature being developed by MIT, which will use an override provider very
much long those lines.
2015-04-06 13:04:44 -07:00