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

Multiple updates in tool_uploadcourse

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 2.6
    • 2.6
    • Administration
    • MOODLE_26_STABLE
    • MOODLE_26_STABLE
    • MDL-41210-master
    • Hide

      During this test, you are making sure that you can restore a course over another one, using the same backup file or course as origin for multiple courses.

      1. Set $CFG->keeptempdirectoriesonbackup to false
      2. Create a basic CSV with also the columns 'backupfile', and 'templatecourse' and add multiple courses to the CSV
        • 2 using the exact same backup file (for column backup file)
        • 2 using the exact same course shortname (for column templatecourse)
      3. Make sure that the backup file has been restored on the targetted courses.
      4. Make sure that the template course has been restored on the targetted courses.
      5. Try again, remove the columns backupfile and templatecourse, and this time select a backup file from the user interface "Restore from this file after upload"
      6. Make sure the backup file selected in the UI has been used for each course
      7. Try again, but set a course shortname to restore from instead "Restore from this course after upload"
      8. Make sure the course specified in the UI has been used to restore the content on each course
      1. Repeat the whole test with $CFG->keeptempdirectoriesonbackup set to true
      Show
      During this test, you are making sure that you can restore a course over another one, using the same backup file or course as origin for multiple courses. Set $CFG->keeptempdirectoriesonbackup to false Create a basic CSV with also the columns 'backupfile', and 'templatecourse' and add multiple courses to the CSV 2 using the exact same backup file (for column backup file) 2 using the exact same course shortname (for column templatecourse) Make sure that the backup file has been restored on the targetted courses. Make sure that the template course has been restored on the targetted courses. Try again, remove the columns backupfile and templatecourse , and this time select a backup file from the user interface "Restore from this file after upload" Make sure the backup file selected in the UI has been used for each course Try again, but set a course shortname to restore from instead "Restore from this course after upload" Make sure the course specified in the UI has been used to restore the content on each course Repeat the whole test with $CFG->keeptempdirectoriesonbackup set to true

      Hehe, continuing testing of tool_couseupload
      I managed to create several empty courses, now I want to import a backup file in them. This is my csv file:

      shortname,backupfile
      C1,/home/marina/repositories/backup-features_demo-26.mbz
      C2,/home/marina/repositories/backup-features_demo-26.mbz
      C3,/home/marina/repositories/backup-features_demo-26.mbz
      C4,/home/marina/repositories/backup-features_demo-26.mbz
      

      I select Upload mode: only update existing
      update mode: update with csv data only

      The backup file is restored ONLY in C1 and then I get an error:

      Upload courses results
       
      error/tmp_backup_directory_not_found
       
      More information about this error
      Debug info:
      Error code: tmp_backup_directory_not_found
      $a contents: [tempdir]/backup/706387b71c41b12aa9cf63be140ca0ae
      Stack trace:
       
          line 140 of /backup/util/helper/convert_helper.class.php: convert_helper_exception thrown
          line 290 of /backup/util/helper/backup_general_helper.class.php: call to convert_helper::detect_moodle2_format()
          line 116 of /backup/controller/restore_controller.class.php: call to backup_general_helper::detect_backup_format()
          line 718 of /admin/tool/uploadcourse/classes/course.php: call to restore_controller->__construct()
          line 205 of /admin/tool/uploadcourse/classes/processor.php: call to tool_uploadcourse_course->proceed()
          line 90 of /admin/tool/uploadcourse/index.php: call to tool_uploadcourse_processor->execute()
      

        1. MFDC23.mbz
          3.61 MB
          Jason Fowler
        2. courses.csv
          0.2 kB
          Jason Fowler

            fred Frédéric Massart
            marina Marina Glancy
            Marina Glancy Marina Glancy
            Sam Hemelryk Sam Hemelryk
            Jason Fowler Jason Fowler
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:

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