Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 2.5
    • Component/s: Lesson
    • Labels:
    • Testing Instructions:
      Hide
      1. Set debugger to 'developer'
      2. Create new lesson
      3. Enable 'Allow student review"
      4. Add a matching question
      5. Add a multiple choices question
      6. Edit the existing questions
      7. Attempt the lesson as student
      8. Review the lesson

      Make sure there is no warning for setType() through out the above process.

      Show
      Set debugger to 'developer' Create new lesson Enable 'Allow student review" Add a matching question Add a multiple choices question Edit the existing questions Attempt the lesson as student Review the lesson Make sure there is no warning for setType() through out the above process.
    • Affected Branches:
      MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_25_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-38714_tmp
    • Rank (Obsolete):
      48796

      Description

      This now triggers debugging messages since MDL-34311.

      Did you remember to call setType() for 'edit'? Defaulting to PARAM_RAW cleaning.
      line 1266 of /lib/formslib.php: call to debugging()
      line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
      line 202 of /lib/formslib.php: call to moodleform->_process_submission()
      line 44 of /mod/lesson/editpage_form.php: call to moodleform->moodleform()
      line 2734 of /mod/lesson/locallib.php: call to lesson_add_page_form_selection->__construct()
      line 69 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
      Did you remember to call setType() for 'score[0]'? Defaulting to PARAM_RAW cleaning.
      line 1266 of /lib/formslib.php: call to debugging()
      line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
      line 202 of /lib/formslib.php: call to moodleform->_process_submission()
      line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
      line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
      Did you remember to call setType() for 'score[1]'? Defaulting to PARAM_RAW cleaning.

        Issue Links

          Activity

          Hide
          Frédéric Massart added a comment -

          Also found that when adding some questions some messages are displayed too

          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.
          line 1275 of /lib/formslib.php: call to debugging()
          line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
          line 202 of /lib/formslib.php: call to moodleform->_process_submission()
          line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
          line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.
          line 1275 of /lib/formslib.php: call to debugging()
          line 919 of /lib/formslib.php: call to moodleform->detectMissingSetType()
          line 129 of /mod/lesson/editpage.php: call to moodleform->display()
          
          Show
          Frédéric Massart added a comment - Also found that when adding some questions some messages are displayed too Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1275 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1275 of /lib/formslib.php: call to debugging() line 919 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 129 of /mod/lesson/editpage.php: call to moodleform->display()
          Hide
          Ankit Agarwal added a comment -

          Hi Rosie,
          As discussed in dev chat

          $this->_form->setType('response_editor', PARAM_TEXT); 
          

          should be

          $this->_form->setType('response_editor['.$count.]', PARAM_TEXT);
          

          similarly it should be done for score as well.
          Rest looks good. I didn't find any orphan text,hidden and url elements in lesson
          Thanks

          Show
          Ankit Agarwal added a comment - Hi Rosie, As discussed in dev chat $ this ->_form->setType('response_editor', PARAM_TEXT); should be $ this ->_form->setType('response_editor['.$count.]', PARAM_TEXT); similarly it should be done for score as well. Rest looks good. I didn't find any orphan text,hidden and url elements in lesson Thanks
          Hide
          Dan Poltawski added a comment -

          I've opened MDL-38885 for that [] problem.

          Show
          Dan Poltawski added a comment - I've opened MDL-38885 for that [] problem.
          Hide
          Rossiani Wijaya added a comment -

          Waiting on the decision for MDL-38885 in order to fix this properly.

          The above patch is based on the current patch available for MDL-38885.

          Show
          Rossiani Wijaya added a comment - Waiting on the decision for MDL-38885 in order to fix this properly. The above patch is based on the current patch available for MDL-38885.
          Hide
          David Monllaó added a comment -

          Adding more debugging messages, they appear when filling a new numerical question, haven't checked other questions:

          Did you remember to call setType() for 'edit'? Defaulting to PARAM_RAW cleaning.
          
              line 1289 of /lib/formslib.php: call to debugging()
              line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
              line 202 of /lib/formslib.php: call to moodleform->_process_submission()
              line 44 of /mod/lesson/editpage_form.php: call to moodleform->moodleform()
              line 2734 of /mod/lesson/locallib.php: call to lesson_add_page_form_selection->__construct()
              line 69 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.
          
              line 1289 of /lib/formslib.php: call to debugging()
              line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
              line 202 of /lib/formslib.php: call to moodleform->_process_submission()
              line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
              line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.
          
              line 1289 of /lib/formslib.php: call to debugging()
              line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
              line 202 of /lib/formslib.php: call to moodleform->_process_submission()
              line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
              line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.
          
              line 1289 of /lib/formslib.php: call to debugging()
              line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
              line 202 of /lib/formslib.php: call to moodleform->_process_submission()
              line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
              line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.
          
              line 1289 of /lib/formslib.php: call to debugging()
              line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
              line 202 of /lib/formslib.php: call to moodleform->_process_submission()
              line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
              line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Did you remember to call setType() for 'edit'? Defaulting to PARAM_RAW cleaning.
          
              line 1289 of /lib/formslib.php: call to debugging()
              line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
              line 202 of /lib/formslib.php: call to moodleform->_process_submission()
              line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
              line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          
          Show
          David Monllaó added a comment - Adding more debugging messages, they appear when filling a new numerical question, haven't checked other questions: Did you remember to call setType() for 'edit'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 44 of /mod/lesson/editpage_form.php: call to moodleform->moodleform() line 2734 of /mod/lesson/locallib.php: call to lesson_add_page_form_selection->__construct() line 69 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'edit'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          Hide
          Stephen Bourget added a comment -

          These appear when adding a new true/false question: (Found while testing MDLQA-5550)

          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.

          line 1289 of /lib/formslib.php: call to debugging()
          line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
          line 202 of /lib/formslib.php: call to moodleform->_process_submission()
          line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
          line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()

          Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning.

          line 1289 of /lib/formslib.php: call to debugging()
          line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
          line 202 of /lib/formslib.php: call to moodleform->_process_submission()
          line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform()
          line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()

          Show
          Stephen Bourget added a comment - These appear when adding a new true/false question: (Found while testing MDLQA-5550 ) Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form() Did you remember to call setType() for 'score'? Defaulting to PARAM_RAW cleaning. line 1289 of /lib/formslib.php: call to debugging() line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType() line 202 of /lib/formslib.php: call to moodleform->_process_submission() line 2734 of /mod/lesson/locallib.php: call to moodleform->moodleform() line 76 of /mod/lesson/editpage.php: call to lesson_page_type_manager->get_page_form()
          Hide
          David Monllaó added a comment -

          Hi,

          As talked yesterday in the meeting room, MDL-38947 was blocked by this issue and we don't know if it will be included in 2.5, MDL-38947 has been integrated with an extra I follow "Continue" step to continue after the blocked redirection provoked by the debugging messages (dev. path, is in integration right now: https://github.com/dmonllao/moodle/compare/MDL-38949_master...MDL-38947_master#L0R58) This issue should remove that step, otherwise the test will fail.

          Show
          David Monllaó added a comment - Hi, As talked yesterday in the meeting room, MDL-38947 was blocked by this issue and we don't know if it will be included in 2.5, MDL-38947 has been integrated with an extra I follow "Continue" step to continue after the blocked redirection provoked by the debugging messages (dev. path, is in integration right now: https://github.com/dmonllao/moodle/compare/MDL-38949_master...MDL-38947_master#L0R58 ) This issue should remove that step, otherwise the test will fail.
          Hide
          Joseph Rézeau added a comment -

          Should not this issue be considered a blocker and be solved before releasing Moodle 2.5 ?

          Show
          Joseph Rézeau added a comment - Should not this issue be considered a blocker and be solved before releasing Moodle 2.5 ?
          Hide
          Rossiani Wijaya added a comment -

          Create temporary fixed until MDL-38885 gets integrated.

          Sending for peer-review.

          Show
          Rossiani Wijaya added a comment - Create temporary fixed until MDL-38885 gets integrated. Sending for peer-review.
          Hide
          Ankit Agarwal added a comment -

          Hi Rosie,
          changes are good, however can you make sure a new issue is created once this is integrated to handle a more elegant solution?
          Also please can you verify the behats are passing with your patch, as they might not (guessing that from David's comments).

          Thanks

          Show
          Ankit Agarwal added a comment - Hi Rosie, changes are good, however can you make sure a new issue is created once this is integrated to handle a more elegant solution? Also please can you verify the behats are passing with your patch, as they might not (guessing that from David's comments). Thanks
          Hide
          Rossiani Wijaya added a comment - - edited

          Hi Ankit,

          Thank you for reviewing.

          I created MDL-39369 to fixed this issue properly.

          Pushing this for integration review.

          Show
          Rossiani Wijaya added a comment - - edited Hi Ankit, Thank you for reviewing. I created MDL-39369 to fixed this issue properly. Pushing this for integration review.
          Hide
          Dan Poltawski added a comment -

          The main moodle.git repository has just been updated with latest weekly modifications. You may wish to rebase your PULL branches to simplify history and avoid any possible merge conflicts. This would also make integrator's life easier next week.

          TIA and ciao

          Show
          Dan Poltawski added a comment - The main moodle.git repository has just been updated with latest weekly modifications. You may wish to rebase your PULL branches to simplify history and avoid any possible merge conflicts. This would also make integrator's life easier next week. TIA and ciao
          Hide
          Damyon Wiese added a comment -

          Thanks Rosie,

          This looks great. Thanks for checking behat too.

          Integrated to master.

          Show
          Damyon Wiese added a comment - Thanks Rosie, This looks great. Thanks for checking behat too. Integrated to master.
          Hide
          David Monllaó added a comment -

          Rossie, you saved a kitty's life

          Show
          David Monllaó added a comment - Rossie, you saved a kitty's life
          Hide
          Rossiani Wijaya added a comment -

          David, is it a Hello Kitty?

          Show
          Rossiani Wijaya added a comment - David, is it a Hello Kitty?
          Hide
          David Monllaó added a comment -

          I hope not

          Show
          David Monllaó added a comment - I hope not
          Hide
          Jérôme Mouneyrac added a comment - - edited

          I tested the test instructions, there are no setType errors. Passed. All little girls and pink manufacturers thank you for saving Hello Kitty.

          However there are few unrelated warnings. Linked/commented an existing issue for them (MDL-37639). Thanks.

          Show
          Jérôme Mouneyrac added a comment - - edited I tested the test instructions, there are no setType errors. Passed. All little girls and pink manufacturers thank you for saving Hello Kitty. However there are few unrelated warnings. Linked/commented an existing issue for them ( MDL-37639 ). Thanks.
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Did you think this day was not going to arrive ever?

          Your patience has been rewarded, yay, sent upstream, thanks!

          Closing...ciao

          Show
          Eloy Lafuente (stronk7) added a comment - Did you think this day was not going to arrive ever? Your patience has been rewarded, yay, sent upstream, thanks! Closing...ciao

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: