Closed vuvanhieu143 closed 7 months ago
Hi @timhunt ,
I have finished implementing the changes for Moodle 4.3. Here's a summary of the modifications made in this commit:
M.util.set_user_preference
in Moodle 4.3 necessitated the use of UserRepository
.Additionally, there are three failed CI issues:
/home/runner/work/moodle-mod_studentquiz/moodle-mod_studentquiz/moodle/mod/studentquiz/classes/condition/studentquiz_condition.php
on line 104. This issue is specific to PHP 7.3, and I don't think we need to fix it.The CI flagged missing PHP documentation for the following functions:
custom_completion::get_state
custom_completion::get_defined_custom_rules
custom_completion::get_custom_rule_descriptions
custom_completion::get_sort_order
However, it appears that these functions are intentionally undocumented, so I think this warning is incorrect.
I forgot to mention, that we did have a new 403 branch, so I have added this to the workflow if you think it is not needed I can remove it.
I will review this once:
It was good to add the extre CI build. However, please set that build to run with PHP 8.2 and ensure that is passing. Thanks.
Hi @timhunt , I have rebased and updated the codes.
So this should be ready for review
Thanks @vuvanhieu143, there is a lot of good stuff here.
Some thoughts:
So, overall, really good. Do you want to address some or all of the above points before I merge it? Thanks.
Hi @timhunt,
Thank you for your feedback.
1) I was not aware of that technique, so I have applied those changes, and we now have only one duplicated class (which I can't remove since their structures are different. I don't think we should write a common function just for the sake to remove duplication).
2) I can't remove it because setUserPreference is only implemented in version 4.3 (in MDL-62859), and it is not backported to the older version.
3) I have fixed almost everything. It turns out our current namespace is wrong, which is why we can't use autoloading. There is one class left "question_bank_filter.php", which I plan to refactor in the next ticket so we can utilize autoloading.
4) Oh, I missed that. Thank you. I have fixed it.
5) I did read mod/quiz/tests/behat/backup.feature, and they still need to press the button in this step: "And I press 'Manage course backups.' We can't remove the XPath because the button doesn't have any specific class to identify."
Hope all changes make sense.
Thanks. That all makes sense. Merged.
Make StudentQuiz working with Moodle 4.3