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

Grade import gives no useful information when an error occurs:

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.6.5, 2.7.2
    • Fix Version/s: 2.6.6, 2.7.3
    • Component/s: Gradebook
    • Labels:
    • Testing Instructions:
      Hide

      Tested by MDL-48010 as the code was submitted in one branch.

      Show
      Tested by MDL-48010 as the code was submitted in one branch.
    • Affected Branches:
      MOODLE_26_STABLE, MOODLE_27_STABLE
    • Fixed Branches:
      MOODLE_26_STABLE, MOODLE_27_STABLE

      Description

      In grade/import/xml/import.php

      $error = '';
      $importcode = import_xml_grades($text, $course, $error);
       
      if ($importcode !== false) {
          // ...
      } else {
          print_error('error', 'gradeimport_xml');
      }
      

      Well, you get some marks for effort. The $error variable is initialised, and import_xml_grades even returns useful information using that argument (passed by reference).

      However, that useful information is not displayed!

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  10/Nov/14