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

Undefined index: assign in /lib/grade/grade_item.php on line 2498 when deleting course or submitting quiz

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      Setup:
      1. Create an course with a student and teacher.

      2. Create an assignment in the course.

      3. Login as the teacher and grade the student in the assignment.

      Test 1 - importing

      4. On the course page, hide the assignment. 

      5. From the course settings menu choose "Import". 

      6. Import the assignment from the same course to the same course.

      7. Verify you do not see "Invalid course module ID" during the import.

      8. Verify you can view both assignments and the gradebook without errors.

       Test 2 - deleting modules.

      9. Create an activity of each of the following types and manually grade a student for each one in the gradebook.

      • Database
      • Lesson
      • External Tool (does not need to be valid - http://www.google.com/ will be OK)
      • SCORM (example file attached to this issue)
      • Workshop

      10. Delete each of these activities

      11. Verify there are no errors shown during deletion.

      Show
      Setup: 1. Create an course with a student and teacher. 2. Create an assignment in the course. 3. Login as the teacher and grade the student in the assignment. Test 1 - importing 4. On the course page, hide the assignment.  5. From the course settings menu choose "Import".  6. Import the assignment from the same course to the same course. 7. Verify you do not see "Invalid course module ID" during the import. 8. Verify you can view both assignments and the gradebook without errors.  Test 2 - deleting modules. 9. Create an activity of each of the following types and manually grade a student for each one in the gradebook. Database Lesson External Tool (does not need to be valid - http://www.google.com/  will be OK) SCORM (example file attached to this issue) Workshop 10. Delete each of these activities 11. Verify there are no errors shown during deletion.
    • Affected Branches:
      MOODLE_36_STABLE, MOODLE_37_STABLE
    • Fixed Branches:
      MOODLE_36_STABLE
    • Pull from Repository:
    • Pull 3.6 Branch:
    • Pull Master Branch:
      MDL-64878-master

      Description

      Hi Guys

      I have read the forums in-particular https://moodle.org/mod/forum/search.php?id=5&search=invalid+course+id

      Everytime i try and delete a course in manage categories under admin menu i get "Invalid course id" and wont let me delete. Also when i try to submit a quiz half way through it also throws up the same error. I have trawled through various topics and tried support channels but no joy. 

      I am running the latest versions of Moodle 3.6.2+ (Build: 20190215)

      along with the latest version of the adaptable theme.

      From conversations i have seen with many people with this issue it seems like its a bug but apologies if i have missed any other reported issues for the same thing, i have tried looking. If anyone can help by looking into this that would be very helpful. 

      Thanks guys for all your hard work

       

        Attachments

        1. 1.png
          1.png
          163 kB
        2. 2.png
          2.png
          140 kB
        3. quiz_bug_3.jpg
          quiz_bug_3.jpg
          34 kB
        4. quiz_bug_4.jpg
          quiz_bug_4.jpg
          128 kB
        5. quiz_bug.jpg
          quiz_bug.jpg
          4 kB
        6. RuntimeMinimumCalls_SCORM12 (1).zip
          350 kB
        7. Screenshot 2019-02-18 at 05.47.34.png
          Screenshot 2019-02-18 at 05.47.34.png
          30 kB
        8. Screenshot 2019-02-18 at 09.51.42.png
          Screenshot 2019-02-18 at 09.51.42.png
          39 kB
        9. Screenshot 2019-02-18 at 09.52.03.png
          Screenshot 2019-02-18 at 09.52.03.png
          30 kB
        10. Screenshot 2019-02-18 at 10.13.19.png
          Screenshot 2019-02-18 at 10.13.19.png
          37 kB
        11. Screenshot 2019-02-18 at 10.13.19.png
          Screenshot 2019-02-18 at 10.13.19.png
          37 kB
        12. Screenshot 2019-02-18 at 10.14.16.png
          Screenshot 2019-02-18 at 10.14.16.png
          95 kB
        13. Screenshot 2019-03-11 at 21.03.50.png
          Screenshot 2019-03-11 at 21.03.50.png
          112 kB
        14. Screenshot 2019-03-11 at 21.03.50.png
          Screenshot 2019-03-11 at 21.03.50.png
          112 kB

          Issue Links

            Activity

              People

              • Votes:
                3 Vote for this issue
                Watchers:
                18 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/Mar/19

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 4 hours, 40 minutes
                  4h 40m