-
Bug
-
Resolution: Fixed
-
Blocker
-
2.8
-
MOODLE_28_STABLE
-
MOODLE_27_STABLE
-
MDL-47835_master -
While testing MDLQA-7562, after doing what appeared to be a successful upgrade I noticed the following error pop up when I went to access a course with recent activities block on it:
[Wed Oct 22 16:32:52.760410 2014] [:error] [pid 14749] [client 24.21.210.156:53722] Default exception handler: Coding error detected, it must be fixed by a programmer: All dataobjects in insert_records() must have the same structure! Debug:
|
Error code: codingerror
|
* line 1284 of /lib/dml/mysqli_native_moodle_database.php: coding_exception thrown
|
* line 306 of /blocks/recent_activity/block_recent_activity.php: call to mysqli_native_moodle_database->insert_records()
|
* line 151 of /blocks/recent_activity/block_recent_activity.php: call to block_recent_activity::migrate_logs()
|
* line 73 of /blocks/recent_activity/block_recent_activity.php: call to block_recent_activity->get_structural_changes()
|
* line 288 of /blocks/moodleblock.class.php: call to block_recent_activity->get_content()
|
* line 230 of /blocks/moodleblock.class.php: call to block_base->formatted_contents()
|
* line 962 of /lib/blocklib.php: call to block_base->get_content_for_output()
|
* line 1014 of /lib/blocklib.php: call to block_manager->create_block_contents()
|
* line 392 of /lib/outputrenderers.php: call to block_manager->ensure_content_created()
|
* line 45 of /theme/clean/layout/columns3.php: call to core_renderer->standard_head_html()
|
* line 915 of /lib/outputrenderers.php: call to include()
|
* line 845 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
|
* line 243 of /course/view.php: call to core_renderer->header(
|
, referer: http://mdlqa7562.jvla.org/course/index.php?categoryid=42
|
For a moment, this error prevented access to the course but when I went back later it seemed to have resolved itself but it may be worth taking a look as to how log migration is taking place.
Eloy commented:
"seems that the built-in migration of information can easily end throwing that "All dataobjects in insert_records() must have the same structure!" because the check @ moodle_database::insert_records() verifying that is really extrict (a simple change in the order of fields for a record leads to the error).
So I'd suggest you to create an issue about it, that should end guarantying that block_recent_activity:.migrate_logs() always return information satisfying moodle_database::insert_records(). Test covered, ideally."
While I did pass the MDLQA-7562, I am going to tag this as a must fix for 2.8. If it proves to be less critical then the issues priority can obviously be downgraded. I'm not really sure what the best category is for this either - we'll start with logging. Peace - Anthony
- Discovered while testing
-
MDLQA-7562 CLONE - Upgrade test using a big data set
- Passed