Commit b6090952 by Chris Dodge

randomize_module.py was missing 'import lxml' to support definition_to_xml().…

randomize_module.py was missing 'import lxml' to support definition_to_xml(). Also, fix serialization of show_timezone to expect a bool
parent a8084628
......@@ -4,6 +4,8 @@ import random
from xmodule.x_module import XModule
from xmodule.seq_module import SequenceDescriptor
from lxml import etree
from xblock.core import Scope, Integer
log = logging.getLogger('mitx.' + __name__)
......
......@@ -136,6 +136,7 @@ class XmlDescriptor(XModuleDescriptor):
'hide_progress_tab': bool_map,
'allow_anonymous': bool_map,
'allow_anonymous_to_peers': bool_map,
'show_timezone': bool_map,
}
......
<course filename="6.002_Spring_2012" slug="6.002_Spring_2012" graceperiod="1 day 12 hours 59 minutes 59 seconds" showanswer="attempted" rerandomize="never" name="6.002 Spring 2012" start="2015-07-17T12:00" course="full" org="edX" />
<course filename="6.002_Spring_2012" slug="6.002_Spring_2012" graceperiod="1 day 12 hours 59 minutes 59 seconds" showanswer="attempted" rerandomize="never" name="6.002 Spring 2012" start="2015-07-17T12:00" course="full" org="edX" show_timezone="true"/>
......@@ -12,4 +12,13 @@
<html slug="html_95">Minor correction: Six elements (five resistors)…</html>
<customtag tag="S1" slug="discuss_96" impl="discuss"/>
</vertical>
<randomize url_name="PS1_Q4" display_name="Problem 4: Read a Molecule">
<vertical>
<html slug="html_900">
<!-- UTF-8 characters are acceptable… HTML entities are not -->
<h1>Inline content…</h1>
</html>
</vertical>
</randomize>
</sequential>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment