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

Student can't submit if the essay question type is in the quiz (2.2)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.2
    • Fix Version/s: 2.1.5, 2.2.2
    • Component/s: Quiz
    • Labels:
    • Environment:
      Moodle 2.2, Oracle
    • Database:
      Oracle
    • Testing Instructions:
      Hide

      This bug needs to be tested on Oracle, but it would be good to repeat the tests on a more common database (that is, MySQL) to verify there are no regressions their either.

      1. Create a quiz and add two essay questions.
      2. The first essay question should allow attachments.
      3. The second essay question should use the HTML editor with the filepicker.
      4. Attempt the quiz as a student.
      5. Attach a file to the first essay question.
      6. Embed an image into your answer for the second question.
      7. Submit the quiz.
      8. As either teacher or student, review the quiz, and make sure the files are all present and correct.
      9. Finally, for good measure, as teacher regrade the quiz (using the button in the Results -> Grades report in the quiz navigation). Make sure the files are still present.

      Show
      This bug needs to be tested on Oracle, but it would be good to repeat the tests on a more common database (that is, MySQL) to verify there are no regressions their either. 1. Create a quiz and add two essay questions. 2. The first essay question should allow attachments. 3. The second essay question should use the HTML editor with the filepicker. 4. Attempt the quiz as a student. 5. Attach a file to the first essay question. 6. Embed an image into your answer for the second question. 7. Submit the quiz. 8. As either teacher or student, review the quiz, and make sure the files are all present and correct. 9. Finally, for good measure, as teacher regrade the quiz (using the button in the Results -> Grades report in the quiz navigation). Make sure the files are still present.
    • Workaround:
      Hide

      After I reviewed the source code carefully, I found line 154 in question/engine/datablib.php, "$value->save_files($stepid, $context)" should return the value. So, just simple change the line to:

      line 154: $value = $value->save_files($stepid, $context);

      Things work as expected. I am not sure this only happens to Oracle or also to other databases.

      Show
      After I reviewed the source code carefully, I found line 154 in question/engine/datablib.php, "$value->save_files($stepid, $context)" should return the value. So, just simple change the line to: line 154: $value = $value->save_files($stepid, $context); Things work as expected. I am not sure this only happens to Oracle or also to other databases.
    • Affected Branches:
      MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      Student cannot submit the essay question after inputting something or attaching a file. After clicking the "Next" button, got the following ORA message: ORA-24343: user defined callback error.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              timhunt Tim Hunt
              Reporter:
              longfeiyu Longfei Yu
              Integrator:
              Sam Hemelryk
              Tester:
              Dan Poltawski
              Participants:
              Component watchers:
              Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                12/Mar/12