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

Universal solution for Moodle cron error: The course module ... could not be deleted.

    XMLWordPrintable

Details

    • Task
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 3.7.5, 3.11.4, 4.1
    • None
    • Backup
    • MOODLE_311_STABLE, MOODLE_37_STABLE, MOODLE_401_STABLE

    Description

      The issue appears in the cron output:
      Adhoc task failed: core_course\task\course_delete_modules, Coding error detected, it must be fixed by a programmer: The course module SOME_CM_ID could not be deleted.

      It would be fine to found an universal solution for this issue.

      The issue appears for different activities.
      It was noticed for:

      • mod_questionnaire
      • mod_bigbluebuttonbn
      • mod_elluminate
      • mod_turnitintooltwo

      It appears when "Enable course recycle bin" is turned on.

      In DB it looks the same for at least most of the cases:

      • No record in plugin's table like mdl_questionnaire or mdl_bigbluebuttonbn,
      • Kept record in mdl_course_modules

       

      Possible solution:

      Check mdl_course_modules table in a cron is there related records in the plugin's tables and remove orphaned course module records.

       

       

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              pfranks Enovation Solutions
              Adrian Greeve, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              16 Vote for this issue
              Watchers:
              22 Start watching this issue

              Dates

                Created:
                Updated: