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

Random question type should be removed (because there are better ways to handle random questions)

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.5
    • Fix Version/s: None
    • Component/s: Questions, Quiz
    • Labels:
      None

      Description

      The ability to select questions at random from the question bank is an important feature. However, the way it is currently implemented, with instances of a fake question type sort-of present in the question bank but hidden, causes no end of problems, particularly with backup and restore. There are better ways to store what is going on.

      For example, in the quiz, the quiz_slots DB table has a questionid column that directly links to the question for non-random questions, and it has columns categoryid + tag + include subcategories, for randomly selected questions. That is the good way to handle this, and does not require qtype_random at all.

      So, qtype_random should be removed (except, possibly, for a stub to support restore of old backups). And all the code simplification that follows from that should be made.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                rezaie9 Shamim Rezaie
                Peer reviewer:
                Tim Hunt
                Participants:
                Component watchers:
                Tim Hunt, Andrew Nicols, Mathew May, Michael Hawkins, Shamim Rezaie, Simey Lameze, Tim Hunt, Andrew Nicols, Mathew May, Michael Hawkins, Shamim Rezaie, Simey Lameze
              • Votes:
                9 Vote for this issue
                Watchers:
                12 Start watching this issue

                Dates

                • Created:
                  Updated: