Moodle
  1. Moodle
  2. MDL-27553

Activity completion not marking correctly

    Details

    • Affected Branches:
      MOODLE_20_STABLE
    • Rank:
      17216

      Description

      When completing a quiz that has a 'grade to pass' specified (http://docs.moodle.org/en/Activity_completion) it marks it as 'Completed' with a tick when the quiz has been finished, regardless of the grade the student accomplished. This happens because the 'Scores' option under the 'Review options' 'Later, while the quiz is still open' was not set. On the documentation page it states 'There is one limitation: this only works if grades are immediately visible to students'. However, when regenerating the results by editing the quiz and choosing 'Unlock Completion Options' and then click 'Save and return to course' it will then display the correct icon (when the user logs in and out as the icon is stored in the user's session), which in this case was supposed to be a cross. I am not sure which behaviour is expected, if it should be a cross or tick or neither when the score is hidden. Either way there are two separate situations happening.

        Activity

        Hide
        Sam Marshall added a comment -

        Hi,

        I think this may be a borderline case but note that I don't understand the quiz very well.

        The correct behaviour is that it should not be possible, using the completion system, to 'see' grades that are hidden. If there is a way to 'see' hidden grades (i.e. if the 'red cross' behaviour operates at a point when the grades are still hidden from students and do not appear in the gradebook) then this is certainly a bug.

        Could you confirm if this occurred - i.e. at the point when you unlocked completion and it then showed the red cross, was that grade currently visible to the student in the gradebook [ok, it's not revealing anything they can't see] or was it hidden [not ok]? If that is wrong, I think I definitely need to fix it.

        Aside from that possible issue, if grades are hidden for a limited time, then when they are unhidden, the completion ticks are not normally updated (I think this is basically because there isn't always something to hook into at that point) so it continues to behave as if they were hidden. This should give consistent results unless you unlock completion options... Not sure if it needs fixing, it's basically done that way because I couldn't think of an easy/efficient way to do it better.

        Show
        Sam Marshall added a comment - Hi, I think this may be a borderline case but note that I don't understand the quiz very well. The correct behaviour is that it should not be possible, using the completion system, to 'see' grades that are hidden. If there is a way to 'see' hidden grades (i.e. if the 'red cross' behaviour operates at a point when the grades are still hidden from students and do not appear in the gradebook) then this is certainly a bug. Could you confirm if this occurred - i.e. at the point when you unlocked completion and it then showed the red cross, was that grade currently visible to the student in the gradebook [ok, it's not revealing anything they can't see] or was it hidden [not ok] ? If that is wrong, I think I definitely need to fix it. Aside from that possible issue, if grades are hidden for a limited time, then when they are unhidden, the completion ticks are not normally updated (I think this is basically because there isn't always something to hook into at that point) so it continues to behave as if they were hidden. This should give consistent results unless you unlock completion options... Not sure if it needs fixing, it's basically done that way because I couldn't think of an easy/efficient way to do it better.
        Hide
        Mark Nelson added a comment -

        Hi Sam,

        Thanks for the quick response.

        Yes, when unlocking the completion and saving, it changed the value of 'completionstate' to a 3, from a 1, in the 'course_modules_completion' table, which meant it displayed the red cross (remember, the student has to log out then back in due to the variable being stored in the SESSION), even though the grade was not selected as visible in the quiz settings.

        Show
        Mark Nelson added a comment - Hi Sam, Thanks for the quick response. Yes, when unlocking the completion and saving, it changed the value of 'completionstate' to a 3, from a 1, in the 'course_modules_completion' table, which meant it displayed the red cross (remember, the student has to log out then back in due to the variable being stored in the SESSION), even though the grade was not selected as visible in the quiz settings.
        Hide
        Sam Marshall added a comment -

        I thought I could reproduce this but in practice I can't, probably because I do not understand how to use the quiz or grade options.

        The key point can be summarised as follows. Assume the student failed. Just before you are going to unlock completion options...

        1) Log in as the student. Their completion tickbox is shown as a plain (black) tick.

        2) From the course page, go to the 'Grades' link. This should show a row regarding the quiz in question. QUESTION: Does that row contain your grade for the quiz, or not?

        3) Log in as admin. Edit quiz settings. Unlock completion options and save.

        4) Log in as the student again (must be fresh login as you note). Look at the completion tickbox. It probably now shows a red X.

        5) From the course page, go to the 'Grades' link. This should show a row regarding the quiz in question. QUESTION: Does that row contain your grade for the quiz, or not?

        The completion system problem would be if the answer to 'QUESTION' in 5 is 'No it does not show your grade' but in 4, the red X is displayed.

        When I tried to reproduce it kept showing me the student's grade in step 5, even though I thought I set it to hidden so that it did not show in step 2. If this is actual behaviour and not just me then it indicates a problem with quiz/gradebook and not completion (when the grade is not hidden, completion is allowed to show it). HOWEVER this may well be because I don't understand how to set up the quiz to hide grades correctly.

        Would it be possible for you to give a sequence of steps to set this up starting from a blank course (created with default options, except completion enabled) and a new quiz - describing all options that need to be changed from the default (in the quiz and in the gradebook) to make this happen? I think I might be doing something wrong with those settings...

        thanks

        Show
        Sam Marshall added a comment - I thought I could reproduce this but in practice I can't, probably because I do not understand how to use the quiz or grade options. The key point can be summarised as follows. Assume the student failed. Just before you are going to unlock completion options... 1) Log in as the student. Their completion tickbox is shown as a plain (black) tick. 2) From the course page, go to the 'Grades' link. This should show a row regarding the quiz in question. QUESTION: Does that row contain your grade for the quiz, or not? 3) Log in as admin. Edit quiz settings. Unlock completion options and save. 4) Log in as the student again (must be fresh login as you note). Look at the completion tickbox. It probably now shows a red X. 5) From the course page, go to the 'Grades' link. This should show a row regarding the quiz in question. QUESTION: Does that row contain your grade for the quiz, or not? The completion system problem would be if the answer to 'QUESTION' in 5 is 'No it does not show your grade' but in 4, the red X is displayed. When I tried to reproduce it kept showing me the student's grade in step 5, even though I thought I set it to hidden so that it did not show in step 2. If this is actual behaviour and not just me then it indicates a problem with quiz/gradebook and not completion (when the grade is not hidden, completion is allowed to show it). HOWEVER this may well be because I don't understand how to set up the quiz to hide grades correctly. Would it be possible for you to give a sequence of steps to set this up starting from a blank course (created with default options, except completion enabled) and a new quiz - describing all options that need to be changed from the default (in the quiz and in the gradebook) to make this happen? I think I might be doing something wrong with those settings... thanks
        Hide
        Sam Marshall added a comment -

        This issue was assigned to me automatically, however I will not be able to work on this issue in the immediate future. In order to create a truer sense of the state of this issue and to allow other developers to have chance to become involved, I am removing myself as the assignee of this issue.

        For more information, see http://docs.moodle.org/dev/Changes_to_issue_assignment

        Show
        Sam Marshall added a comment - This issue was assigned to me automatically, however I will not be able to work on this issue in the immediate future. In order to create a truer sense of the state of this issue and to allow other developers to have chance to become involved, I am removing myself as the assignee of this issue. For more information, see http://docs.moodle.org/dev/Changes_to_issue_assignment

          People

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

            Dates

            • Created:
              Updated: