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

Database error when creating assignment with remind me to grade by unchecked

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 3.7
    • Assignment
    • MOODLE_37_STABLE
    • MDL-66603-master
    • Hide

      I don't think it's reasonable to re-create the bug in a testing environment. You'd need ~70,000 random rows in mdl_event table, plus traffic. Confirm that the index is created in both the installation and upgrade scenarios is probably enough.

      Show
      I don't think it's reasonable to re-create the bug in a testing environment. You'd need ~70,000 random rows in mdl_event table, plus traffic. Confirm that the index is created in both the installation and upgrade scenarios is probably enough.

      In some cases, creating an assignment with 'remind me to grade by' unchecked fails with the following error:

      Debug info: Deadlock found when trying to get lock; try restarting transaction
      DELETE FROM mdl_event WHERE modulename = ? AND instance = ? AND eventtype = ?
      [array (
      0 => 'assign',
      1 => '53500',
      2 => 'gradingdue',
      )]
      Error code: dmlwriteexception
      Stack trace:
      line 489 of /lib/dml/moodle_database.php: dml_write_exception thrown
      line 1625 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
      line 1911 of /lib/dml/moodle_database.php: call to mysqli_native_moodle_database->delete_records_select()
      line 1227 of /mod/assign/locallib.php: call to moodle_database->delete_records()
      line 702 of /mod/assign/locallib.php: call to assign->update_calendar()
      line 41 of /mod/assign/lib.php: call to assign->add_instance()
      line 124 of /course/modlib.php: call to assign_add_instance()
      line 154 of /course/modedit.php: call to add_moduleinfo()

      We're currently running 3.7.1+, but have seen this issue since about 3.3.x. It's intermittent, occuring during busy times.

      Related bugs -
      https://tracker.moodle.org/browse/CONTRIB-7241
      https://tracker.moodle.org/browse/MDL-63732

            cfulton Charles Fulton
            adamann2 Ann Adamcik
            Peter Dias Peter Dias
            Votes:
            13 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 35 minutes
                35m

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