vfremaux / moodle-mod_flashcard

A mpdule providing a memoizong helper activity using Leitner model
5 stars 10 forks source link

M3.0+ compatibility notices/execptions shown when using module instance #9

Open logan-reynolds opened 7 years ago

logan-reynolds commented 7 years ago

When adding an instance to a Moodle 3.1 or 3.2 course using the latest MOODLE_31_STABLE branch commitid e6ceef0, I'm seeing that the instance of flashcard module is throwing several notices/exceptions with debugging on, one related to a typo in the OUTPUT var. This leads me to think some functionality of flashcard isn't fully functioning and needs to be updated to possibly remove update_module_button calls, correct typo, and address other features that work differently in M3.0 upwards:

line 1827 of /lib/setuplib.php: call to core_renderer->update_module_button() line 80 of /mod/flashcard/view.php: call to bootstrap_renderer->__call() Notice: Undefined variable: OUTPU in /var/www/html/moodletest/mod/flashcard/checkview.php on line 47 Exception - Call to a member function continue_button() on null Debug info: Error code: generalexceptionmessage Stack trace: line 47 of /mod/flashcard/checkview.php: Error thrown line 235 of /mod/flashcard/view.php: call to include()`

When adding cards I'm also seeing it drop styles/images and display the following:

core_renderer::update_module_button() has been deprecated and should not be used anymore. Activity modules should not add the edit module button, the link is already available in the Administration block. Themes can choose to display the link in the buttons row consistently for all module types. line 2651 of /lib/outputrenderers.php: call to debugging() line 1827 of /lib/setuplib.php: call to core_renderer->update_module_button() line 80 of /mod/flashcard/view.php: call to bootstrap_renderer->__call() You should really redirect before you start page output line 976 of /lib/outputrenderers.php: call to debugging() line 2816 of /lib/weblib.php: call to core_renderer->redirect_message() line 232 of /mod/flashcard/editview.php: call to redirect() line 222 of /mod/flashcard/view.php: call to include()

vfremaux commented 7 years ago

thanks Logan for input. I'm getting a quick version review to fix raise ups in higher version branches