-
Bug
-
Resolution: Duplicate
-
Minor
-
None
-
3.2.5
-
MOODLE_32_STABLE
This issue seems to have occurred due to their being recycle bin items due for removal, but the course is deleted prior to the items being removed via the scheduled task.
The course with ID 29 is no longer present in the database.
I've attached the SQL statement being executed by the scheduled task.
Stack trace from running the scheduled task manually :-
php admin/tool/task/cli/schedule_task.php --execute='\tool_recyclebin\task\cleanup_course_bin' --showdebugging
Execute scheduled task: Cleanup course recycle bin (tool_recyclebin\task\cleanup_course_bin)
[tool_recyclebin] Deleting item '703' from the course recycle bin ...
... used 4 dbqueries
... used 0.012587785720825 seconds
Scheduled task failed: Cleanup course recycle bin (tool_recyclebin\task\cleanup_course_bin),Can not find data record in database table course.
Debug info:
SELECT id,category FROM {course} WHERE id = ?
[array (
0 => '29',
)]
Backtrace:
- line 1502 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()
- line 6644 of /lib/accesslib.php: call to moodle_database->get_record()
- line 277 of /admin/tool/recyclebin/classes/course_bin.php: call to context_course::instance()
- line 61 of /admin/tool/recyclebin/classes/task/cleanup_course_bin.php: call to tool_recyclebin\course_bin->delete_item()
- line 146 of /admin/tool/task/cli/schedule_task.php: call to tool_recyclebin\task\cleanup_course_bin->execute()
- duplicates
-
MDL-57486 Improve fault tolerance of category and course bin cleanup tasks
-
- Closed
-