Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-42115

Statistics report on empty quiz shows an exception

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.6
    • Fix Version/s: 2.6
    • Component/s: Questions, Quiz
    • Labels:

      Description

      Create a quiz and before adding any questions to it view the statistics report.

      This looks like a recent regression, can not be reproduced on 2.5

      Coding error detected, it must be fixed by a programmer: moodle_database::get_in_or_equal() does not accept empty arrays
       
      More information about this error
      Debug info:
      Error code: codingerror
      Stack trace:
       
          line 687 of /lib/dml/moodle_database.php: coding_exception thrown
          line 368 of /question/engine/datalib.php: call to moodle_database->get_in_or_equal()
          line 287 of /question/classes/statistics/questions/calculator.php: call to question_engine_data_mapper->load_questions_usages_latest_steps()
          line 81 of /question/classes/statistics/questions/calculator.php: call to core_question\statistics\questions\calculator->get_latest_steps()
          line 510 of /mod/quiz/report/statistics/report.php: call to core_question\statistics\questions\calculator->calculate()
          line 131 of /mod/quiz/report/statistics/report.php: call to quiz_statistics_report->get_quiz_and_questions_stats()
          line 100 of /mod/quiz/report.php: call to quiz_statistics_report->display()
      
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jamiesensei Jamie Pratt
              Reporter:
              marina Marina Glancy
              Peer reviewer:
              Tim Hunt
              Integrator:
              Dan Poltawski
              Tester:
              Dan Poltawski
              Participants:
              Component watchers:
              Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                18/Nov/13