How to recover this blocked quiz submission?

How to recover this blocked quiz submission?

by Visvanath Ratnaweera -
Number of replies: 3
Picture of Particularly helpful Moodlers Picture of Translators
I have a case of a blocked quiz submission. The quiz was set to "When time expires : Attempts must be submitted before time expires, or they are not counted". The quiz lasts 35 min. The session time-out of the site is 60 min. The quiz ran without problems except for one candidate. His result is tagged "Never submitted" and the report is empty, just hyphens. If I go to "Review attempt" I can see some answers.

The problem is, I can not grade those answers even manually. There is no "Make comment or override mark" button. How can I unblock this quiz submission?

I understand https://docs.moodle.org/31/en/Quiz_FAQ#How_can_a_.22Never_submitted_quiz.22_be_submitted.3F as a No. Either change the quiz settings - for that it is too late now - or enter the grade manually in the grade book.

The second question is, when exactly does this happen? I can not reconstruct the situation. My dummy users in the same quiz, who answer a few questions and then do nothing, do not submit, their submissions get "Finished" status. Could it mean that in the final minute the network connection was down?

Moodle version 3.1.8
Average of ratings: -
In reply to Visvanath Ratnaweera

Re: How to recover this blocked quiz submission?

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Found the answer to the second question: When does this happen? Pretty simple. Start the quiz, answer a question or two on the first page, go to the second page and close the browser!

The remaining question is how to unblock the submission? Setting a flag in the database is also OK.
In reply to Visvanath Ratnaweera

Re: How to recover this blocked quiz submission?

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

I guess I would start with the question attempts table and see if there is a locked field there that you can change - compare a blocked attempt with a normal one.

In reply to Visvanath Ratnaweera

Re: How to recover this blocked quiz submission?

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

That FAQ you found is the right answer. Well, wrong answer from your point of view.

This might work, but no guarantees:

  • Change the quiz setting for "When time expires" to "Submit automatically".
  • In the quiz_attempts table, change the attempt state from 'abandoned' to 'inprogress'. (And, possibly, set timecheckstate to 1.)
  • Wait for the quiz cron to run.

No promises, that but that might work. I suggest you test it on a test server before doing something like that in your live database.

Average of ratings: Useful (1)