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

Error when viewing 'restore page' link during asynchronous course restore

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.7.6, 3.8.3
    • 3.7.3, 3.8.1, 3.9
    • Backup
    • MOODLE_37_STABLE, MOODLE_38_STABLE, MOODLE_39_STABLE
    • MOODLE_37_STABLE, MOODLE_38_STABLE
    • Hide
      1. Ensure cron is disabled (this gives time to view the restore page before the process completes)
      2. Login as admin
      3. Navigate to Courses > Backups > Asynchronous backup/restore in site administration
      4. Tick Enable asynchronous backups and save changes
      5. Create a new course
      6. Press the Actions menu and select Restore
      7. Under Import a backup file upload backup-moodle2-course-3-lovely-20200313-2336-nu.mbz and press Restore
      8. Press Continue
      9. Select Delete the contents of this course and then restore and press Continue
      10. Press Next
      11. Press Next (again)
      12. Press Perform restore
      13. Under the heading The restore process is pending press the link in the text You can check the progress at any time on the restore page.
      14. Confirm the Restores in progress table displays the status as Process pending
      15. Enable cron and let the async restore complete
      16. Confirm the Restores in progress table displays the status as a tick (success) - this happens asynchronously, you may need to wait a few seconds
      Show
      Ensure cron is disabled (this gives time to view the restore page before the process completes) Login as admin Navigate to Courses > Backups > Asynchronous backup/restore in site administration Tick Enable asynchronous backups and save changes Create a new course Press the Actions menu and select Restore Under Import a backup file upload backup-moodle2-course-3-lovely-20200313-2336-nu.mbz and press Restore Press Continue Select Delete the contents of this course and then restore and press Continue Press Next Press Next (again) Press Perform restore Under the heading The restore process is pending press the link in the text You can check the progress at any time on the restore page . Confirm the Restores in progress table displays the status as Process pending Enable cron and let the async restore complete Confirm the Restores in progress table displays the status as a tick (success) - this happens asynchronously, you may need to wait a few seconds

      Description:

      When deleting contents and restoring into a course, if a user clicks the 'restore page' link in the given message (async backup/restore) an error is generated

      Prerequisites:

      Asynchronous backup/restore enabled in <site>/admin/settings.php?section=asyncgeneralsettings

      Go any course and run a full backup to generate an MBZ file

      Steps to replicate:

      1. Access a course
      2. Course Administration>Restore>Drag and drop the backup file
      3. Click on Restore
      4. Click on Continue
      5. Select the option 'Delete the contents of this course then restore' option under 'Restore into this course' and click on Continue
      6. Click on Next, Next, Perform restore.
      7. In the message below, click on the hyperlink 'Restore page' while the restore is pending

      Observed result:

      Error message appears

      error/setting_by_name_not_found

      More information about this error

      ×Debug info:
      Error code: setting_by_name_not_found
      $a contents: filename
      ×Stack trace:
      line 124 of /backup/util/plan/base_plan.class.php: base_plan_exception thrown
      line 314 of /backup/util/helper/async_helper.class.php: call to base_plan->get_setting()
      line 606 of /backup/util/ui/renderer.php: call to async_helper::get_async_backups()
      line 462 of /lib/outputrenderers.php: call to core_backup_renderer->render_backup_files_viewer()
      line 541 of /backup/util/ui/renderer.php: call to plugin_renderer_base->render()
      line 166 of /backup/restorefile.php: call to core_backup_renderer->backup_files_viewer()

      Expected result:

      Page appears with status of the restore

            pholden Paul Holden
            prankin Phillip Rankin
            Mihail Geshoski Mihail Geshoski
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Anna Carissa Sadia Anna Carissa Sadia
            Votes:
            2 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 5 minutes
                2h 5m

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