Commit Graph

1898 Commits

Author SHA1 Message Date
Jesse Shapiro
9a573de533 Add consent check to course access prerequisites; add utility functions to provide interface to course-specific consent in Enterprise app 2017-02-09 13:49:57 -05:00
David Ormsbee
5ef1e08050 Disable student state writes for crawlers.
When crawlers like edX-downloader make requests on courseware, they are
often concurrently loading many units in the same sequence. This causes
contention for the rows in courseware_studentmodule that store the
student's state for various XBlocks/XModules, most notably for the
sequence, chapter, and course -- all of which record and update user
position information when loaded.

It would be nice if we could actually remove these writes altogether
and come up with a cleaner way of keeping track of the user's position.
In general, GETs should be side-effect free. However, any such change
would break backwards compatibility, and would require close
coordination with research teams to make sure they weren't negatively
affected.

This commit identifies crawlers by user agent (CrawlersConfig model),
and blocks student state writes if a crawler is detected. FieldDataCache
writes simply become no-ops. It doesn't actually alter the rendering
of the courseware in any way -- the main impact is that the blocks
won't record your most recent position, which is meaningless for
crawlers anyway.

This can also be used as a building block for other policy we want to
define around crawlers. We just have to be mindful that this only works
with "nice" crawlers who are honest in their user agents, and that
significantly more sophisticated (and costly) measures would be
necessary to prevent crawlers that try to be even trivially sneaky.

[PERF-403]
2017-01-26 09:36:53 -05:00
Nimisha Asthagiri
5a9179bf00 Update has_database_updated_with_new_score to handle all block types
TNL-6331
2017-01-23 15:50:16 -05:00
Christina Roberts
b9c3848449 Merge pull request #14337 from edx/christina/tnl-6050
Allow "masquerading as a group member" in Preview
2017-01-19 15:49:02 -05:00
cahrens
a6776f6973 Always check group access when masquerading.
TNL-6050
2017-01-19 14:47:10 -05:00
Eric Fischer
507e621ccc Revert "Merge pull request #14324 from edx/efischer/revertins"
This reverts commit c7d2d601b8, reversing
changes made to fb2173f43e.
2017-01-18 10:56:13 -05:00
Ari Rizzitano
54a48a3227 [courseware] generate sequence-specific titles server-side (AC-695)
[courseware] generate sequence-specific titles server-side (AC-695)

[courseware] generate sequence-specific titles server-side (AC-695)

case for empty subsections [AC-695]

move title logic into courseware context method [AC-695]

pep8

coffeescript -> js

js mistake

jslint

refactor sequence title generation slightly

missed a line

line too long

python is not javascript

ugh js

ugh js part 2
2017-01-14 17:55:09 -05:00
alisan617
88e10e0ee8 sequence navs keyboard support and test update 2017-01-13 14:07:10 -05:00
Eric Fischer
0b620ebbc1 Revert "Merge pull request #14225 from edx/efischer/tnl-6108"
This reverts commit 8b8cf5f9e0, reversing
changes made to 2716ffbf8e.
2017-01-12 13:50:05 -05:00
Eric Fischer
6845c64977 Hide after course end
Hijacks the existing hide_after_due field to be repected as "hide after course
end" for self-paced courses. Includes tests.

TNL-6108
2017-01-12 09:12:54 -05:00
Nimisha Asthagiri
99e6d53939 Preload definitions when collecting block structures 2016-12-29 08:51:26 -05:00
Jillian Vogel
eef4539355 Merge pull request #14153 from open-craft/jill/fix-insights-ccx-staff
Checks access using the CCX course key instead of the base course key
2016-12-23 08:20:24 +10:30
Dmitry Viskov
fc0577d081 Hide bookmarks link in the LTI mode 2016-12-22 09:56:33 -05:00
Jillian Vogel
8493ff6028 Checks access using the CCX course key,
instead of using the base course key (which does not contain the CCX info).
This removes the need for special checking of CCXKey/CCXLocator types, and just
treats them like normal CourseKeys.

This fix allows users with a Staff role on a CCX course to view CCX courses in Insights.
2016-12-22 08:37:49 +10:30
asadazam93
01f3233a50 Fix InvalidKeyError on render xblock 2016-12-20 13:03:50 +05:00
Eric Fischer
5a98a90eba Use timestamps in _has_database_updated_with_new_score check
Also fixes issue where ORA grades were never updated, by including
them in this check.

TNL-5994
TNL-5995
2016-12-09 13:46:34 -05:00
Nimisha Asthagiri
aca69f78f2 Update Subsection Grade Report to differentiate Not Attempted and 0
TNL-5990
2016-11-30 12:36:26 -05:00
Nimisha Asthagiri
e87388e24c Grades cleanup before updating grade report
Remove deprecated SingleSectionGrader.  TNL-5987
Remove display_name and module_id from Scores objects
Update CourseGradeFactory.__init__ to not be user-specific
Update some callers to use CourseGrade class instead of "summary" dict
Remove no longer needed course_grades.py module.
Renamed django signal from GRADES_UPDATED to COURSE_GRADE_CHANGED
2016-11-30 12:36:25 -05:00
Sanford Student
4eb5311ece Separating problem raw score changed and problem weighted score changed signals
For TNL-5993
2016-11-30 10:15:07 -05:00
Albert St. Aubin
282ded7442 Addressed test failures and PR comments
TNL-5894
2016-11-28 07:12:23 -05:00
Toby Lawrence
c67ee94d80 Merge pull request #13996 from edx/PERF-321
[PERF-321] Move heavy JS files for WordCloud out of lms-modules.js
2016-11-21 13:49:00 -05:00
Adam
0fbe384248 Merge pull request #14006 from edx/adam/fix-date-unicode-issue
use a QueryDict to encode a url param that potentially has unicode (E…
2016-11-21 12:59:00 -05:00
Adam Palay
10b33c8a8d use a QueryDict to encode a url param that potentially has unicode (ECOM-6390) 2016-11-18 09:31:51 -05:00
Toby Lawrence
a49227661b undo the test shenanigans i was doing 2016-11-17 09:49:42 -05:00
Gregory Martin
707371e1d7 Refactor info.html page datetime rendering 2016-11-17 08:54:08 -05:00
Toby Lawrence
da664ce7f8 quality fix 2016-11-15 15:03:29 -05:00
Toby Lawrence
f136911eaa quality fix 2016-11-15 14:19:41 -05:00
Toby Lawrence
842e9dce56 test fix - this is so stupid 2016-11-15 13:42:09 -05:00
Gregory Martin
08c5a35899 Merge pull request #13923 from edx/yro_fix-PR-13794
Yro fix PR 13794
2016-11-08 10:06:16 -05:00
Noraiz
bc3cbf57b5 Video download button does not appear in course (TNL-5769) 2016-11-08 12:39:03 +05:00
Gregory Martin
e05cb31b87 fix leading zero bok choy 2016-11-07 18:43:16 -05:00
Gregory Martin
f0cd29f02a Revert "Merge pull request #13915 from edx/revert-13794-yro_implement-dateutil"
This reverts commit d59ab18b27, reversing
changes made to 0ebab35e89.
2016-11-07 17:04:13 -05:00
J. Cliff Dyer
9366c43a83 Fix issues with RequestFactory used as Request.
* Centralize creation of quick request objects.
* Isolate caches to individual tests to prevent test ordering
  dependencies.

TNL-5811
2016-11-07 10:51:04 -05:00
Jesse Zoldak
ec880138d2 Revert "Implement DateUtils in LMS" 2016-11-04 07:50:26 -04:00
Gregory Martin
3fd16eb6be Implement DateUtils in LMS 2016-11-03 10:06:10 -04:00
Sanford Student
a1d5ea905d Persistent Course Grades Glue Layer
Initial commit

TNL-5484
2016-10-27 14:56:45 -04:00
Nimisha Asthagiri
4a20370f37 Update CourseGradeFactory.create to be read_only by default
TNL-5835
2016-10-25 20:49:43 -04:00
Eric Fischer
6a47311479 Update Persisted Course Grade on Subsection Grade update
Makes use of the new SUBSECTION_SCORE_CHANGED signal to trigger a task that
updates persisted course grade values. We've also renamed SCORE_CHANGED to
PROBLEM_SCORE_CHANGED to head off any issues with unclear signal names.

TNL-5740
2016-10-25 14:47:31 -04:00
Albert (AJ) St. Aubin
c01df60014 Merge pull request #13786 from edx/aj/TNL-5549_problemMetaRefactor
Aj/tnl 5549 problem meta refactor
2016-10-21 13:03:32 -04:00
Albert St. Aubin
dbb66f8c09 Updated the problem meta to show a score of 0 and refactored/simplified the JS that build the problem meta string
TNL-5549
2016-10-21 06:40:20 -04:00
Nimisha Asthagiri
aa000c1a3d Support for rescoring a problem only if the new score is higher
TNL-5046
2016-10-20 15:08:54 -04:00
Christina Roberts
046ee7bd96 Merge pull request #12923 from CredoReference/static-page-for-instructors-only
Ability to hide Pages from students
2016-10-17 17:10:33 -04:00
Dmitry Viskov
bb09fdb7be Ability to hide Pages from students 2016-10-14 22:43:26 +03:00
Greg Martin
4ddda443b8 Implement localized datetimes in browser
moment-timezone require config

jasmine test fix, duplicate req. cleanup
2016-10-14 15:25:38 -04:00
alisan617
21eb03e116 Merge pull request #13513 from edx/alisan/inline-discussion-TNL-4756
New inline discussion home view TNL-4756
2016-10-14 12:09:42 -04:00
alisan617
d5635cf1ba New inline discussion home view UI
TNL-4756
2016-10-14 10:54:50 -04:00
Eric Fischer
0928cfde80 Merge pull request #13734 from edx/efischer/async_grade
Update persistent grades asynchronously
2016-10-13 15:02:44 -04:00
Eric Fischer
70e029b1f5 Update persistent grades asynchronously
For better user-facing performance, the SCORE_CHANGED signal is now handled by
enqueueing an async task to update the relevant stored grade, rather than
making the request wait until that operation finishes.

TNL-5738
2016-10-13 14:06:06 -04:00
Andy Armstrong
4d4097e13c Move dark_lang and lang_pref apps to openedx/core 2016-10-13 11:56:24 -04:00
Andy Armstrong
684aec8740 Move contentserver to openedx/core 2016-10-11 12:49:33 -04:00