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

Problem in grade category

    XMLWordPrintable

Details

    • MySQL
    • MOODLE_21_STABLE, MOODLE_23_STABLE
    • MOODLE_23_STABLE, MOODLE_24_STABLE
    • MDL-29877_bad_grade_item
    • Hide

      Restore the attached backup into a new course. Go to the grade book and check that it loads without error. (MDL-37676 actually fixed the restore process but it doesnt hurt to double check)

      In another course with one or more graded activities and one or more students.

      You're going to make a series of modifications before reloading the user report and the grader report so keep them open in separate tabs.

      Modify category aggregation type.

      While category aggregation is set to sum of grades set "drop lowest" to some number.

      Set some grade items to be extra credit.

      Check you dont get any errors.

      Show
      Restore the attached backup into a new course. Go to the grade book and check that it loads without error. ( MDL-37676 actually fixed the restore process but it doesnt hurt to double check) In another course with one or more graded activities and one or more students. You're going to make a series of modifications before reloading the user report and the grader report so keep them open in separate tabs. Modify category aggregation type. While category aggregation is set to sum of grades set "drop lowest" to some number. Set some grade items to be extra credit. Check you dont get any errors.

    Description

      When i click Grades in some courses (3 out of 100) i get these errors and then i get memory exhausted:

      Notice: Undefined index: in ../lib/grade/grade_category.php on line 1126 Notice: Trying to get property of non-object in ../lib/grade/grade_category.php on line 1126 Warning: array_key_exists() expects parameter 2 to be array, null given in ../lib/grade/grade_category.php on line 1126 Notice: Undefined property: stdClass::$path in ../lib/grade/grade_category.php on line 1142 Notice: Undefined property: stdClass::$id in /var/www/eclass2/lib/grade/grade_category.php on line 1142 Notice: Undefined property: stdClass::$id in ../lib/grade/grade_category.php on line 1144
      Attempt to obtain a grade_category's associated grade_item without the category's ID being set.

      line 1253 of /lib/grade/grade_category.php: call to debugging()
      line 1241 of /lib/grade/grade_category.php: call to grade_category->get_grade_item()
      line 212 of /lib/grade/grade_category.php: call to grade_category->load_grade_item()
      line 1146 of /lib/grade/grade_category.php: call to grade_category->update()
      line 1019 of /lib/grade/grade_category.php: call to grade_category->get_children()
      line 1646 of /grade/lib.php: call to grade_category::fetch_course_tree()
      line 130 of /grade/report/grader/lib.php: call to grade_tree->grade_tree()
      line 114 of /grade/report/grader/index.php: call to grade_report_grader->__construct()

      Can not regrade non existing category

      line 393 of /lib/grade/grade_category.php: call to debugging()
      line 235 of /lib/grade/grade_category.php: call to grade_category->qualifies_for_regrading()
      line 1146 of /lib/grade/grade_category.php: call to grade_category->update()
      line 1019 of /lib/grade/grade_category.php: call to grade_category->get_children()
      line 1646 of /grade/lib.php: call to grade_category::fetch_course_tree()
      line 130 of /grade/report/grader/lib.php: call to grade_tree->grade_tree()
      line 114 of /grade/report/grader/index.php: call to grade_report_grader->__construct()

      Can not update grade object, no id!

      line 214 of /lib/grade/grade_object.php: call to debugging()
      line 241 of /lib/grade/grade_category.php: call to grade_object->update()
      line 1146 of /lib/grade/grade_category.php: call to grade_category->update()
      line 1019 of /lib/grade/grade_category.php: call to grade_category->get_children()
      line 1646 of /grade/lib.php: call to grade_category::fetch_course_tree()
      line 130 of /grade/report/grader/lib.php: call to grade_tree->grade_tree()
      line 114 of /grade/report/grader/index.php: call to grade_report_grader->__construct()

      PHP Notice: Undefined property: stdClass::$id in ../lib/grade/grade_category.php

      If it helps,we don't use grade categories and all these are set to uncategorised.

      Attachments

        Issue Links

          Activity

            People

              andyjdavis Andrew Davis
              chrodos Christos Rodosthenous
              Jason Fowler Jason Fowler
              Damyon Wiese Damyon Wiese
              Ankit Agarwal Ankit Agarwal
              Adrian Greeve, Ilya Tregubov, Kevin Percy, Mathew May, Mihail Geshoski, Shamim Rezaie
              Votes:
              20 Vote for this issue
              Watchers:
              20 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                13/May/13