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

Moodle XML export for calculated question produces incorrect correctanswerlength

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.9.5
    • 1.7.7+, 1.8.10, 1.9.6
    • Questions
    • None
    • Don't know what specifications are for server, can find out if you want. Not 100% sure about the moodle version either, though I will check.
    • MOODLE_19_STABLE
    • MOODLE_17_STABLE, MOODLE_18_STABLE, MOODLE_19_STABLE

    Description

      Calculated questions exported in Moodle XML format do not set the correct "Correct Answer Shows"

      To reproduce:
      Make a new calculated question.
      Enter any name, question text "

      {x}" and correct answer formula "{x}

      ".
      Export question.

      Expected: <correctanswerlength> tag set to 2 (the default value)
      Actual: <correctanswerlength> tag is set to 1

      Importing the exported XML confirms the problem:
      Import the file you exported above.
      Edit question.
      Expected: "Correct answer shows" will still be 2 (as originally set)
      Actual: "Correct answer shows" is 1

      The value written out seems to depend on "Tolerance Type". It is 1 for geometric and relative regardless of the value set in writing the question. It is 2 for nominal regardless of the value set in writing the question.

      Attachments

        Activity

          People

            ppichet Pierre Pichet
            mcraig Matt Craig
            Sam Hemelryk Sam Hemelryk
            Safat Shahin, Tim Hunt, Andrew Lyons, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Stevani Andolo
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              21/Oct/09