ndunand / moodle-mod_choicegroup

Moodle "Group Choice" plugin
https://moodle.org/plugins/mod_choicegroup
34 stars 57 forks source link

Could not update choicegroup, Error code: cannotupdatemod #197

Closed Richardvi closed 8 months ago

Richardvi commented 1 year ago

When selecting groups in the group choice module and pressing 'save' this is the error we get (with full debugging on)

Unfortunately, I don't have any other information... the debugging shows very little info.

Could not update choicegroup

More information about this error

Debug info: Error code: cannotupdatemod×Dismiss this notification Stack trace: line 660 of /course/modlib.php: moodle_exception thrown line 173 of /course/modedit.php: call to update_moduleinfo()

image

Richardvi commented 1 year ago

Found more info in the error-log:

[05-Sep-2023 13:59:34 Europe/Amsterdam] PHP Warning: Undefined property: stdClass::$option in /home/learn/public_html/mod/choicegroup/mod_form.php on line 218 [05-Sep-2023 13:59:34 Europe/Amsterdam] PHP Warning: foreach() argument must be of type array|object, null given in /home/learn/public_html/mod/choicegroup/mod_form.php on line 218 [05-Sep-2023 13:59:34 Europe/Amsterdam] PHP Warning: Attempt to read property "uservisible" on null in /home/learn/public_html/course/format/tabs/lib.php on line 94 [05-Sep-2023 13:59:34 Europe/Amsterdam] Default exception handler: Could not update choicegroup Debug: Error code: cannotupdatemod

ndunand commented 1 year ago

Hi, Thanks for reporting . Could you get us the following extra information?

Richardvi commented 1 year ago

Yes, sorry. Moodle 4.2.2, PHP 8.0, choicegroup 1.41 for Moodle 3.9-4.2 (Build: 2023061400)

Richardvi commented 1 year ago

It could be a duplicate of https://github.com/ndunand/moodle-mod_choicegroup/issues/189

pmatabiau commented 11 months ago

Hi, here too. (Moodle 4.1.4+, mod_choicegroup version 2023061400). voegii fix works fine (since Mars 1). Please accept the pull requests and publish a new version.

Richardvi commented 10 months ago

Any progress on this? Some of my teachers are getting annoyed by this bug. Publishing a new version like @pmatabiau says would help us as well!

NicoAlexH commented 8 months ago

Fixed by merging https://github.com/ndunand/moodle-mod_choicegroup/pull/190