Commit 7f004872 by Will Daly

Reverted last commit due to concerns about database writes.

parent b76adb4b
......@@ -171,8 +171,6 @@ class CapaModule(CapaFields, XModule):
# add extra info and raise
raise Exception(msg), None, sys.exc_info()[2]
# Ensure that the module state matches the state of the
# capa problem
self.set_state_from_lcp()
def new_lcp(self, state, text=None):
......
......@@ -868,7 +868,10 @@ class CapaModuleTest(unittest.TestCase):
module = CapaFactory.create(rerandomize=rerandomize)
# Get the seed
seed = module.seed
# This isn't stored in the XModule until
# we check/save/reset the problem, so we
# access the lcp seed directly
seed = module.lcp.seed
self.assertTrue(seed is not None)
# If we're not rerandomizing, the seed is always set
......@@ -928,7 +931,10 @@ class CapaModuleTest(unittest.TestCase):
module = CapaFactory.create(rerandomize=rerandomize)
# Get the seed
seed = module.seed
# This isn't stored in the XModule until
# we check/save/reset the problem, so we
# access the lcp seed directly
seed = module.lcp.seed
# We do NOT want the seed to reset if rerandomize
# is set to 'never' -- it should still be 1
......
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