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

Potential race condition in grade_categories would raise an App error

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: BACKEND
    • Fix Version/s: None
    • Component/s: Gradebook
    • Labels:
      None

      Description

      I am using Moodle version 20. 

      In function process_grade_category() in file restore_stepslib.php, a new category is checked if exists and inserted. It could happen that two concurrent requests inserting the same category to the table. The database will not report any error, but when reloading the page, an application error will be raised. It seems the table is missing a unique constraint?

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            Case_qiu CaseKK
            Participants:
            Component watchers:
            Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: