If we can't parse policy, then set it to an empty dictionary

This commit is contained in:
Calen Pennington
2013-03-06 15:18:03 -05:00
parent 4cbae2269c
commit 4327aa1885

View File

@@ -342,7 +342,7 @@ class CourseDescriptor(SequenceDescriptor):
policy = json.loads(cls.read_grading_policy(paths, system))
except ValueError:
system.error_tracker("Unable to decode grading policy as json")
policy = None
policy = {}
# cdodge: import the grading policy information that is on disk and put into the
# descriptor 'definition' bucket as a dictionary so that it is persisted in the DB