-
Bug
-
Resolution: Fixed
-
Critical
-
2.5.6, 2.6.3, 2.7
-
MOODLE_25_STABLE, MOODLE_26_STABLE, MOODLE_27_STABLE
-
MOODLE_26_STABLE, MOODLE_27_STABLE
-
Because of MDL-38846, when you lose your login session, the quiz auto-save code does not detect it, and so does not warn you. Hence you can lose a lot of work.
To reproduce
- (Optional) Add $CFG->forced_plugin_settings = array('quiz' => array('autosaveperiod' => 3)); to your config.php to make thes easier to test. (Just a 3 second delay between a change and an auto-save.)
- Create a quiz containing one question, e.g. one truefalse.
- Attempt the quiz, and Open the console. (The autosave code outputs useful debug messages to tell you what is going on - assuming you have developer debug on.)
- Use your browser's developer tools to change the value of the sesskey hidden input.
- Change the answer to the truefalse question, and wait for the Autosave to run. Note that it appears to succeed.
- Click next. Notice that you get a sesskey error.
At the penultimate step above, the red connection error should appear at the top of the page.