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

Grade items restored incorrectly cause recursion, memory limit exceeded error

    Details

    • Testing Instructions:
      Hide

      You'll need a 1.9 backup. Restore the backup into a 2.x site and check that the backup restores without error. There is one attached that you can use.

      Perform a backup and restore within your 2.x site just to make sure that that all still works fine.

      MDL-29877 will fix previouly restored grade items so don't worry about that.

      Show
      You'll need a 1.9 backup. Restore the backup into a 2.x site and check that the backup restores without error. There is one attached that you can use. Perform a backup and restore within your 2.x site just to make sure that that all still works fine. MDL-29877 will fix previouly restored grade items so don't worry about that.
    • Affected Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE
    • Pull Master Branch:

      Description

      Refer to MDL-37672. Restoring a course backup made in 1.9 which is missing all grade categories, but still has manual grade items that reference those absent categories, will incorrectly insert the grade items with a null category id.

      This will cause a recursion/memory exhaustion error when trying to access the course's Grades interface, as the null category id is unanticipated.

      Suggested fix is to not allow an import of a manual grade item with a null category id. If the mapping (backup_ids_temp) fails, use the course's grade category as a default.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  11 Vote for this issue
                  Watchers:
                  9 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    13/May/13