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

Course Recycle bin scheduled task unable to complete

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 3.2.5
    • Course
    • 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()

       

       

            Unassigned Unassigned
            jamie.biddulph Jamie Biddulph
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

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