We are trying to import a section from one course into another. We tried using the import function and the restore into an existing course and are getting the error below. Has anyone else encountered this? We are running: Moodle 3.2.1 (Build: 20170109) Version 2016120501
Notice: Trying to get property of non-object in /var/www/moodle/backup/moodle2/restore_stepslib.php on line 4477
Coding error detected, it must be fixed by a programmer: Invalid context id specified context::instance_by_id()
More information about this error
Debug info:
Error code: codingerror
Stack trace:
line 5477 of /lib/accesslib.php: coding_exception thrown
line 4477 of /backup/moodle2/restore_stepslib.php: call to context::instance_by_id()
line 137 of /backup/util/plan/restore_structure_step.class.php: call to restore_create_categories_and_questions->process_tag()
line 103 of /backup/util/helper/restore_structure_parser_processor.class.php: call to restore_structure_step->process()
line 178 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 177 of /backup/util/plan/base_plan.class.php: call to base_task->execute()
line 167 of /backup/util/plan/restore_plan.class.php: call to base_plan->execute()
line 335 of /backup/controller/restore_controller.class.php: call to restore_plan->execute()
line 162 of /backup/import.php: call to restore_controller->execute_plan()
Thank you in advance!