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

Error restoring backup containing LTI module.

    XMLWordPrintable

Details

    • MOODLE_28_STABLE
    • MOODLE_28_STABLE
    • MDL-46451_restoreError
    • Hide

      Ticket description pretty much covers it, but just in case:

      • Must have Postgres as the DB.
      • Restore the attached Moodle backup file.
      • It should restore correctly. Also, confirm the LTI activity's grade. The grade should be 100.
      Show
      Ticket description pretty much covers it, but just in case: Must have Postgres as the DB. Restore the attached Moodle backup file. It should restore correctly. Also, confirm the LTI activity's grade. The grade should be 100.

    Description

      I took a backup of a course from Mount Orange demo school (http://school.demo.moodle.net/course/view.php?id=39) without user data and attempted to restore it on a local site.
      When trying to restore I encountered a fatal error:

      I've attached the exact backup used to this issue. It is consistently reproducible.

      Error writing to database
       
      Debug info: ERROR: invalid input syntax for integer: "100.00000"
      INSERT INTO mdl_lti (name,intro,introformat,timecreated,timemodified,typeid,toolurl,securetoolurl,launchcontainer,instructorchoicesendname,instructorchoicesendemailaddr,instructorchoiceacceptgrades,instructorchoiceallowroster,instructorchoiceallowsetting,grade,instructorcustomparameters,debuglaunch,showtitlelaunch,showdescriptionlaunch,icon,secureicon,course,servicesalt) VALUES($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21,$22,$23) RETURNING id
      [array (
      'name' => 'Chemvantage Atoms and Elements Quiz',
      'intro' => '<p>This is a link to a chemistry quiz from the ChemVantage site. The ChemVantage site is an example of an LTI compliant site which means it will connect to Moodle via the <a href="http://docs.moodle.org/en/External_tool" target="_blank">External Tool module</a> and will allow Moodle users to go directly to the relevant page without needing to log in again. Many LTI sites also send back grades to Moodle\'s gradebook.</p>',
      'introformat' => '1',
      'timecreated' => '1351682321',
      'timemodified' => '1400656384',
      'typeid' => 0,
      'toolurl' => 'http://chem-vantage.appspot.com/lti/',
      'securetoolurl' => '',
      'launchcontainer' => '3',
      'instructorchoicesendname' => '1',
      'instructorchoicesendemailaddr' => '1',
      'instructorchoiceacceptgrades' => '1',
      'instructorchoiceallowroster' => NULL,
      'instructorchoiceallowsetting' => NULL,
      'grade' => '100.00000',
      'instructorcustomparameters' => '',
      'debuglaunch' => '0',
      'showtitlelaunch' => '1',
      'showdescriptionlaunch' => '1',
      'icon' => '',
      'secureicon' => '',
      'course' => 6,
      'servicesalt' => '53cc3f12425bd2.18875446',
      )]
      Error code: dmlwriteexception
       
      Stack trace:
       
          line 446 of /lib/dml/moodle_database.php: dml_write_exception thrown
          line 244 of /lib/dml/pgsql_native_moodle_database.php: call to moodle_database->query_end()
          line 868 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->query_end()
          line 924 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->insert_record_raw()
          line 83 of /mod/lti/backup/moodle2/restore_lti_stepslib.php: call to pgsql_native_moodle_database->insert_record()
          line 137 of /backup/util/plan/restore_structure_step.class.php: call to restore_lti_activity_structure_step->process_lti()
          line 103 of /backup/util/helper/restore_structure_parser_processor.class.php: call to restore_structure_step->process()
          line 151 of /backup/util/xml/parser/processors/grouped_parser_processor.class.php: call to restore_structure_parser_processor->dispatch_chunk()
          line 91 of /backup/util/helper/restore_structure_parser_processor.class.php: call to grouped_parser_processor->postprocess_chunk()
          line 148 of /backup/util/xml/parser/processors/simplified_parser_processor.class.php: call to restore_structure_parser_processor->postprocess_chunk()
          line 92 of /backup/util/xml/parser/processors/progressive_parser_processor.class.php: call to simplified_parser_processor->process_chunk()
          line 190 of /backup/util/xml/parser/progressive_parser.class.php: call to progressive_parser_processor->receive_chunk()
          line 278 of /backup/util/xml/parser/progressive_parser.class.php: call to progressive_parser->publish()
          line ? of unknownfile: call to progressive_parser->end_tag()
          line 179 of /backup/util/xml/parser/progressive_parser.class.php: call to xml_parse()
          line 158 of /backup/util/xml/parser/progressive_parser.class.php: call to progressive_parser->parse()
          line 110 of /backup/util/plan/restore_structure_step.class.php: call to progressive_parser->process()
          line 181 of /backup/util/plan/base_task.class.php: call to restore_structure_step->execute()
          line 192 of /backup/moodle2/restore_activity_task.class.php: call to base_task->execute()
          line 177 of /backup/util/plan/base_plan.class.php: call to restore_activity_task->execute()
          line 167 of /backup/util/plan/restore_plan.class.php: call to base_plan->execute()
          line 333 of /backup/controller/restore_controller.class.php: call to restore_plan->execute()
          line 184 of /backup/util/ui/restore_ui.class.php: call to restore_controller->execute_plan()
          line 107 of /backup/restore.php: call to restore_ui->execute()
      

      Attachments

        Issue Links

          Activity

            People

              bushido Mark Nielsen
              samhemelryk Sam Hemelryk
              Damyon Wiese Damyon Wiese
              Marina Glancy Marina Glancy
              Frédéric Massart Frédéric Massart
              Adrian Greeve, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, Jake Dallimore, Ilya Tregubov, Kevin Percy, Mathew May, Mihail Geshoski, Shamim Rezaie
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                10/Nov/14