Best practice forum (Archived)

Possible Bug in the Assignment Upload Activity

 
A Eisenberg
Possible Bug in the Assignment Upload Activity
by Alan Eisenberg - Tuesday, 24 September 2013, 5:25 AM
 

We have discovered a possible bug in the Assignment Upload activity.

When one of our users uploads a file (PDF or otherwise) with a long name that has spaces such as "JohnSmith – Certification –20140907_4228.pdf", the file uploads fine, but then when you click it you get an error message saying "Sorry the Requested File Cannot Be Found" (See attached picture with debug message turned on).

If the file name is changed to something simpler such as "JohnSmith20140907.pdf", then it uploads and opens fine if clicked on. Also note that if I bulk zip download all of the attachments, the long name file is in there and can be opened fine. It just seems to be a problem when you click one with a long name and spaces in the file.

We did not seem to have this issue in the old 1.x version, but only when we upgraded to 2.4. We tried doing a fresh install of 2.4, but the problem still persists. It seems to be a bug. Has anyone else experienced this issue with the new Assignment Upload module? Does this seems to be a bug with Moodle or with Totara or both?

Thank you for your help.

Alan Eisenberg


me
Re: Possible Bug in the Assignment Upload Activity
by George Angus - Tuesday, 24 September 2013, 8:44 PM
Group Totara

Hi Alan,

I could only recreate this (with the same error message)  when I changed the uploaded file as a user, then tried to access the old file as an admin under grading submissions without refreshing the page. COuld this be the problem? I had no issues with the file names.

cheers,

George.

A Eisenberg
Re: Possible Bug in the Assignment Upload Activity
by Alan Eisenberg - Wednesday, 25 September 2013, 4:39 AM
 

Hi George:

I tried a few things.

1. Upload the file as user and then click on it as user - get the same error message

2. Log in as the trainer and try to open the file - get the same error message

3. Log in as administrator and open the file - get the same error message

To make sure it wasn't a browser issue I tried this in Crome, IE, and Firefox, all with the same issue of not opening the file until it is renamed to something simpler. Again, if I chose download all submissions from Grading action, it will download it in a zip and I can open it, but clicking on it with the name issue to look at it seems to be the problem without simplifying the name.

I experimented and I found that if I remove the dashes ( - ), then the file works, so it seems to not like the dashes. It seems OK with spaces and underscores. Not sure where to go next with this issue.

b/r,

Alan

me
Re: Possible Bug in the Assignment Upload Activity
by George Angus - Wednesday, 25 September 2013, 5:13 PM
Group Totara

Hi Alan,

I cut and pasted your filename - and on 2.2.23 & 2.4.10 on Chrome and Opera had no problems. Ive done a little digging around on Moodle - and found something similar - https://tracker.moodle.org/browse/MDL-32833 but strange its working Ok for me, there is some useful info in the comments.

George.

A Eisenberg
Re: Possible Bug in the Assignment Upload Activity
by Alan Eisenberg - Thursday, 26 September 2013, 5:27 AM
 

George:

Upon further research, I noted in the link you sent that it said if you turned off SLASHARGUMENTS at Site Administration -> Server -> HTTP (see picture below), it might fix it, but it could render SCORM and other items to not work. This was set to YES for us.

I set it to NO and tried again and then the file would open. But I don't think I can have this set to No (or unchecked). Is your testing condition checked or unchecked? Is there a good workaround or do we need to tell all our people to be careful about naming convention if this is checked. Seems like an issue of some sort that could be fixed.

Further thoughts?

b/r,

Alan

me
Re: Possible Bug in the Assignment Upload Activity
by George Angus - Sunday, 29 September 2013, 5:44 PM
Group Totara

Hi Alan,

Turning slash arguments on or off made no difference for me. There is some more info here: http://docs.moodle.org/25/en/Internet_Information_Services#Fix_UTF-8_file_names

It could be the long dashes which are causing the problem.

regards

cheers,

George.