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

Question bank duplication occurs when a quiz is restored multiple times

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • None
    • 4.0.8, 4.2
    • Questions, Quiz
    • None
    • MOODLE_400_STABLE, MOODLE_402_STABLE
    • Hide
      1. Create a quiz in course A
      2. Add one new question to the quiz (any type)
      3. Add one existing question from the course's question bank (this is to rule out any issues with individual questions)
      4. Create a backup of the course A's quiz from the quiz page by going to More > Backup
      5. Go through the backup steps (leave the default settings as they are)
      6. Complete the backup process
      7. To restore this quiz into a different course, in the quiz page, click More > Restore
      8. Scroll down to the User private backup area and click Restore on the most recent backup file 
      9. In the Destination step, select to restore the quiz into an existing course 
      10. Complete the restore process (leave the default settings as they are) 
      11. At the end of the restore process, course B will be displayed on the screen
      12. Open another browser tab and navigate to course A, then to the quiz that was initially created
      13. Check that the quizzes in course A and course B look exactly the same 
      14. Edit a question in course A's quiz (the easiest is to edit the question title - I changed a letter in the question title to a capital letter). Then click Save
      15. Go to the quiz in course B in the other browser tab, reload the page. The change in course A's quiz question doesn't get reflected in the same question in course B's quiz because this is the first restore.
      16. Repeat step 4 to 15, the new change now gets reflected in the same question in course B's quiz. 
      Show
      Create a quiz in course A Add one new question to the quiz (any type) Add one existing question from the course's question bank (this is to rule out any issues with individual questions) Create a backup of the course A's quiz from the quiz page by going to More > Backup Go through the backup steps (leave the default settings as they are) Complete the backup process To restore this quiz into a different course, in the quiz page, click More > Restore Scroll down to the User private backup area and click Restore on the most recent backup file  In the Destination step, select to restore the quiz into an existing course  Complete the restore process (leave the default settings as they are)  At the end of the restore process, course B will be displayed on the screen Open another browser tab and navigate to course A, then to the quiz that was initially created Check that the quizzes in course A and course B look exactly the same  Edit a question in course A's quiz (the easiest is to edit the question title - I changed a letter in the question title to a capital letter). Then click Save Go to the quiz in course B in the other browser tab, reload the page. The change in course A's quiz question doesn't get reflected in the same question in course B's quiz because this is the first restore. Repeat step 4 to 15, the new change now gets reflected in the same question in course B's quiz. 

      When a quiz from course A is restored into course B multiple times with the restore being done in the quiz page, from the second restore, it creates a dynamic link between two quizzes' set of questions. That is, if you modify the questions in Moodle shell A, the update will be reflected in Moodle shell B. 

      I have tested this in Moodle Demo using two Mount Orange School courses and above are the steps to reproduce the error, which I followed and documented.

      This shouldn't be the expected behaviour as a new instance of the quiz/quiz questions should be created in course B. 

      I couldn't reproduce this same error when doing the backup/restore in the course main page by going to More > Course reuse. It seems to only happen when the backup/restore is done from the quiz page. 

            timhunt Tim Hunt
            huongtrinh Huong Trinh
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.