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

Documents with names of more that 90 characters fail to download

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 3.4.2
    • Assignment
    • None
    • MOODLE_34_STABLE

      Documents with names of more than 90 characters, including spaces and the file extension fail to download.  A student is able to upload a document with a name of more than 90 characters, but when a teacher attempts to open the file, they receive the following error:

      Exception - Call to undefined function get_mimetypes_array()

      Debug info:
      Error code: generalexceptionmessage

      Stack trace: •line 999 of \lib\moodlelib.php: Error thrown
      •line 1022 of \lib\moodlelib.php: call to clean_param()
      •line 1001 of \lib\setuplib.php: call to clean_param()
      •line 839 of \lib\setuplib.php: call to setup_get_remote_url()
      •line 734 of \lib\setup.php: call to initialise_fullme()
      •line 39 of \config.php: call to require_once()
      •line 30 of \pluginfile.php: call to require_once()

      Steps to replicate:

      1. In a course with at least one student and teacher, create an assignment.
      2. As the student, create a MS word document (.docx file).  Save the file with a name consisting of more that 90 characters (this can include spaces and the file extension).  Upload the document to the assignment.
      3. As the teacher, navigate to the assignment > View all submissions > click on the file name under File submission to either open or download the file. You should receive the error above if Developer debugging is enabled.

      The environment this was tested in was Moodle 3.4.2, MS Windows Server 2016, SQL Server 2014, PHP 7.1

            Unassigned Unassigned
            thomas-its Thomas College ITS
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.