Repository navigation
Fix compatibility with Moodle >= 5.1 - #7
Conversation
…reports\attempts_report The quiz_attempts_report class was deprecated in Moodle 4.2 (2023-04-24) and finally removed in Moodle 5.1 (2025-10-06).
|
@ngandrass thanks for this Niels. If we accept this into "master" as you suggest, then the plugin will work on Moodle 5.1, but not on earlier versions. Is that correct? |
|
Hi @sangwinc, thanks for reviewing. If accepted, the plugin will require Moodle 4.2 since this is where the new Any Moodle version below 4.2 is EOL for at least three years by now. So this should be fine to merge into master IMHO. But please decide for yourself. Kind regards |
|
Thanks for sorting this out so carefully @ngandrass, much appreciated. |
|
Would it be possible to publish this new version in Moodle Marketplace?? |
On Moodle 5.1 an up, accessing the STACK response analysis report throws the following error:

This is due to the final removal of
/mod/quiz/report/attemptsreport.phpin favor of\mod_quiz\local\reports\attempts_report. The oldattemptsreport.phpwas deprecated in Moodle 4.2 and finally removed in Moodle 5.1.Since any Moodle >= 4.2 ships the new class and any Moodle <= 4.1 is EOL for at least three years, this PR replaces the old library with the new class. This is compatible with any Moodle >= 4.2 and fixes the fatal error on Moodle >= 5.1.