Moodle
  1. Moodle
  2. MDL-24658

Exercise - League Table Error When userid Is 0

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Won't Fix
    • Affects Version/s: 1.9.9
    • Fix Version/s: STABLE backlog
    • Component/s: Other
    • Labels:
      None
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_19_STABLE
    • Rank:
      1210

      Description

      The League table is looking up the "teacher" submission which is assigned userid = 0 in the mdl_exercise_submissions table.

      Since user 0 does not exist, it always shows the error:

      Print league table: user not found

      A patch is attached for mod/exercise/locallib.php that fixes this error by adding an if statement to continue when userid = 0 in:

      function exercise_print_league_table($exercise) {

      To reproduce the issue, view the League table for any exercise activity with submissions.

        Activity

        Chris Follin created issue -
        Mark Nielsen made changes -
        Field Original Value New Value
        Fix Version/s 1.9.10 [ 10407 ]
        Difficulty Easy
        Martin Dougiamas made changes -
        Fix Version/s 1.9.11 [ 10410 ]
        Fix Version/s 1.9.10 [ 10407 ]
        Martin Dougiamas made changes -
        Workflow jira [ 39507 ] MDL Workflow [ 46894 ]
        Martin Dougiamas made changes -
        Fix Version/s 1.9.12 [ 10536 ]
        Fix Version/s 1.9.11 [ 10410 ]
        Martin Dougiamas made changes -
        Workflow MDL Workflow [ 46894 ] MDL Full Workflow [ 75120 ]
        Martin Dougiamas made changes -
        Fix Version/s STABLE backlog [ 10463 ]
        Fix Version/s 1.9.12 [ 10536 ]
        Chris Follin made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Won't Fix [ 2 ]
        Michael de Raadt made changes -
        Component/s Other [ 10063 ]
        Component/s Exercise [ 10074 ]

          People

          • Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: