Skip to content
Snippets Groups Projects
Commit c12c9bbe authored by Andreas Klöckner's avatar Andreas Klöckner
Browse files

Advise about ineffective permissions for non-in-progress flows

parent 39e894ce
No related branches found
No related tags found
No related merge requests found
......@@ -659,6 +659,16 @@ def validate_session_access_rule(vctx, location, arule, tags):
"%s, permission %d" % (location, j+1),
perm)
if hasattr(arule, "if_in_progress") and not arule.if_in_progress:
from course.constants import flow_permission
if (
flow_permission.submit_answer in arule.permissions
or flow_permission.end_session in arule.permissions):
vctx.add_warning(location,
_("Rule specifies 'submit_answer' or 'end_session' "
"permissions for non-in-progress flow. These "
"permissions will be ignored."))
def validate_session_grading_rule(
vctx, # type: ValidationContext
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment