Commit Graph

9300 Commits

Author SHA1 Message Date
Braden MacDonald
1382bf8720 Save user state for Blockstore XBlocks in CSM, clean up CSM a bit (#21630)
This commit introduces the changes needed for XBlocks in Blockstore to save
their user state into CSM. Before this commit, all student state for Blockstore
blocks was ephemeral (in-process dict store).

Notes:

* The main risk factor of this PR is that it adds non-course keys to the
  course_id field in CSM. If any code (like analytics?) reads course keys
  directly out of CSM and doesn't have graceful handling for key types it
  doesn't recognize, it could cause an issue. With the included changes to
  opaque-keys, calling CourseKey.from_string(...) on these values will raise
  InvalidKeyError since they're not CourseKeys. (But calling
  LearningContextKey.from_string(...) will work for both course and library
  keys.)
* This commit introduces a slight regression for the Studio view of XBlocks in
  Blockstore content libraries: their state is now lost from request to request.
  I have a follow up PR to give them a proper studio-appropriate state store,
  but I want to review it separately so it doesn't hold up this PR and we can
  test this PR on its own.
2019-09-18 10:27:46 -04:00
aarif
8e7406493c python 3 fixes
test fixes

changes made as suggested

test fixes

test fixes for python 2

test fixes

python 3 fixes

test fixes

changes made as suggested

test fixes

test fixes for python 2

test fixes

minor fixes

python 3 fixes

minor changes
2019-09-18 16:42:37 +05:00
Ayub
eefa0092d0 Merge pull request #21669 from edx/BOM-450
BOM-450
2019-09-17 10:12:05 +05:00
Feanil Patel
fb59752c75 Need to return a unicode string in the xml factory.
The underlying data is put into json documents that expect unicode
strings not byte strings.  In python2 lxml provided strings that were
auto coerced but in python3 it provides byte strings.
2019-09-16 11:30:05 -04:00
Ayub khan
89b48d3723 BOM-450
python3 compatibility
2019-09-16 17:06:39 +05:00
Ayub
71a593f68c Merge pull request #21641 from edx/BOM-435
BOM-435
2019-09-16 09:58:50 +05:00
Awais Qureshi
5b8e194f81 Merge pull request #21657 from edx/awais786/BOM-478
BOM-478
2019-09-14 02:03:03 +05:00
Awais Qureshi
1de1e72b43 BOM-478
Fixing python3
2019-09-13 18:29:08 +05:00
Awais Qureshi
68ecbc0432 BOM-477
Fixing python3
2019-09-13 17:31:02 +05:00
Ayub khan
a0e0b13eae BOM-435
python3 compatibility
2019-09-13 15:32:16 +05:00
Aarif
072f878b90 Merge pull request #21637 from edx/BOM-446
BOM-446
2019-09-13 14:40:36 +05:00
Feanil Patel
d1728b3d6a Fixes for bokchoy running in python3. 2019-09-12 10:18:46 -04:00
aarif
9301ec38f3 python 3 fixes 2019-09-12 17:29:34 +05:00
DawoudSheraz
652dee611f send grace period info to edx-proctoring 2019-09-12 15:01:32 +05:00
David Ormsbee
c96d0437c8 Merge pull request #21215 from open-craft/jill/capa-dom
LX-309 Modify CAPA choicegroup problems to make custom radio/checkboxes possible
2019-09-11 12:26:01 -04:00
Ayub
bcad9519bc Merge pull request #21528 from edx/BOM-398
BOM-398
2019-09-11 12:29:24 +05:00
Jillian Vogel
fb981bfbbe Aids styleability of CAPA checkbox and radio problems
by making CAPA <input> elements siblings of their <label>s, instead of children.

Also:

* Moves radio submitted status block down below the problem
  to match the checkbox problem status blocks.
* Marks submitted choicegroup answers with a class
2019-09-11 13:54:07 +09:30
Braden MacDonald
48ee155af8 Minor fixes for blockstore runtime 2019-09-09 15:59:29 -07:00
Awais Qureshi
a57d1fd7da BOM-133
python3 tests failures.
2019-09-06 18:22:51 +05:00
edx-pipeline-bot
38cc1f0ab7 Merge pull request #21586 from edx/private_to_public_f98c819
Mergeback PR from private to public.
2019-09-06 12:32:38 +05:00
Awais Jibran
f98c819f74 Merge pull request #160 from edx/aj/add-noopener-to-new-window-urls
Update hyperlinks in platfrom
2019-09-06 11:43:38 +05:00
Ayub khan
df45007ce8 BOM-235
python3 compatibility
2019-09-05 16:32:57 +05:00
Ayub khan
0dc180ddc3 BOM-398
py3 combatibility - test fix
2019-09-03 13:45:15 +05:00
Ayub khan
da9c71557b -Remove unicode and use six.text_type 2019-09-02 16:14:02 +05:00
Aarif
85f622f0e1 Merge pull request #21515 from edx/BOM-362
BOM-362 Python 3 fixes
2019-09-02 14:34:46 +05:00
Ayub khan
8e71206312 BOM-96
-fixes all issues
2019-09-02 13:30:33 +05:00
Aarif
40f4ab2b90 Merge pull request #21487 from edx/BOM-161
BOM-161 Python 3 fixes
2019-09-02 12:34:05 +05:00
Braden MacDonald
d3f6ed09d8 Learning Contexts, New XBlock Runtime, Blockstore API Client + Content Libraries
https://github.com/edx/edx-platform/pull/20645

This introduces:
* A new XBlock runtime that can read and write XBlocks that are persisted using
  Blockstore instead of Modulestore. The new runtime is currently isolated so
  that it can be tested without risk to the current courseware/runtime.
* Content Libraries v2, which store XBlocks in Blockstore not modulestore
* An API Client for Blockstore
* "Learning Context" plugin API. A learning context is a more abstract concept
  than a course; it's a collection of XBlocks that serves some learning purpose.
2019-08-30 10:31:15 -07:00
aarif
e60f767fc4 python 3 fixes
minor fix
2019-08-30 18:01:16 +05:00
aarif
d4924d661e python 3 fixes 2019-08-29 17:32:49 +05:00
aarif
d355dbbef4 python 3 fixes 2019-08-28 16:34:48 +05:00
Awais Jibran
1a4eb7d2e8 Pervent reverse tabnabbing in edx platform 2019-08-28 16:08:34 +05:00
Farhanah Sheets
5fa3024a54 Merge pull request #21441 from edx/azarembok/youtube-disable-flag
PROD-202: Add per-course flag to block access to youtube videos.
2019-08-27 10:16:29 -04:00
Ayub khan
8c4848ae35 BOM-397
py3 compatibility and test fix
2019-08-26 16:53:27 +05:00
Alan Zarembok
b953841893 PROD-202: Add per-course flag to block access to youtube videos. Can be set
for courses that have lost access to their youtube channels.
2019-08-25 14:45:16 -04:00
Ayub khan
67224f401a BOM-90
Made all tests py3 compatible.
2019-08-22 13:04:05 +05:00
noraiz-anwar
1c4f9da92d improved quality of multiple files 2019-08-22 12:47:08 +05:00
Ayub
85be57b64a Merge pull request #21397 from edx/BOM-95
BOM-95
2019-08-22 12:41:08 +05:00
Feanil Patel
f332b81e4c Merge pull request #21384 from edx/bom/python-3-swarm
Bom/python 3 swarm
2019-08-21 09:27:59 -04:00
Ayub khan
8a95a8e520 BOM-95
assertItemsEqual with six.assertCountEqual
2019-08-21 17:01:40 +05:00
Bill DeRusha
aebdf77f8e Revert "PROD-145: Added validation to discussion topic input in studio, testing 2" 2019-08-20 20:31:15 -04:00
Feanil Patel
fde27196f9 Fix quality issues. 2019-08-20 18:02:30 -04:00
Feanil Patel
73a146fbbe Revert "assertItemsEqual() moved to assertCountEqual()"
This reverts commit 3d2617983b.

The change was not quite right because the method six provides needs to
have `self` be passed in as well.  See the docs here:
https://six.readthedocs.io/#unittest-assertions

Reverting for now and we can fix it in smaller chunks later.
2019-08-20 15:31:20 -04:00
Dave St.Germain
3d2617983b assertItemsEqual() moved to assertCountEqual() 2019-08-19 17:00:17 -04:00
Dave St.Germain
aaf7ddd3f3 Correctly encode and decode 2019-08-19 16:08:38 -04:00
Dave St.Germain
e64c61160e Iterating dictionaries 2019-08-19 14:54:03 -04:00
Jeremy Bowman
97c0684755 Cleaner fix for byte conversion in from_xml 2019-08-19 14:26:08 -04:00
Ned Batchelder
f17f9d3862 All of the fall 2012 courses have been imported by now. 2019-08-19 12:43:09 -04:00
David Ormsbee
95a4e9ba3c Fix BlockTransformer Py3 issues (#21376)
Django's reverse can handle Unicode for arguments.
2019-08-19 12:16:39 -04:00
Feanil Patel
085b6b9468 Fix runtime error where dict is modified during iteration. 2019-08-19 11:16:29 -04:00