The Instructure Community will enter a read-only state on November 22, 2025 as we prepare to migrate to our new Community platform in early December.
Read our blog post for more info about this change.
When a student submits a file to an assignment more than once, Canvas will re-name the re-submitted file:
The first submission of HelloWorld.java is named HelloWorld.java
The second submission of HelloWorld.java is named HelloWorld-1.java
The third submission of HelloWorld.java is named HelloWorld-2.java
etc.
(This always causes a certain amount of consternation for my beginning programming students who have been taught that the exact name of a file is very important in the programming language they are learning - Java, C++, Matlab, etc. - and know that, for example, you cannot compile and run a Java file named HelloWorld-1.java.)
Obviously, when I go to grade the student, I will grab their most recent submission (unless they have left me a comment asking me to use an earlier submission), and currently I have to add code to my grading scripts code to fix the names of the students' files before I can compile and run them.
Question 1: Is there any way to turn off the renaming feature in Canvas, even if only when downloading?
I understand completely why renaming is happening, so if the answer is "not in Canvas as it is", I'm perfectly fine with that - I just thought I'd check.
Question 2: Has the way Canvas renames files like this been consistent (or has Canvas previously used other renaming approaches / are there plans to use a new renaming approach)?
I ask this because D2L (my previous LMS) also did file renaming, much of which wasn't apparent until you downloaded a student's submission and found a bunch of somewhat decipherable stuff prepended and/or appended to the file name (or sometimes even the file extension). They also frequently changed the format of what they were prepending/appending which meant frequent updates to those sections of my grading scripts.
Solved! Go to Solution.
Hello @hasti - This has come up a few times in the past in this Community. Not surprisingly, the ever-knowledgeable @James ' explanation of things (with an assist from Kona!) helps clarify a few things as to what's going on with this: Resubmit assignment but keep original filename? One suggestion I've given to my own computer science faculty is to have students such programming assignments in a ZIP file. You would obviously have to download these as opposed to seeing them in SpeedGrader in some cases, but it may help with this specific issue.
Since Canvas is going to mark this assumed answered otherwise, let me post the results:
Question 1: No one has any idea if this feature can be turned off.
Question 2: No one knows (or is willing to say) whether Canvas has been consistent in its naming techniques.
Hello @hasti - This has come up a few times in the past in this Community. Not surprisingly, the ever-knowledgeable @James ' explanation of things (with an assist from Kona!) helps clarify a few things as to what's going on with this: Resubmit assignment but keep original filename? One suggestion I've given to my own computer science faculty is to have students such programming assignments in a ZIP file. You would obviously have to download these as opposed to seeing them in SpeedGrader in some cases, but it may help with this specific issue.
As someone teaching students with no prior programming experience, the benefits of being able to pull up their assignment and look at it in the Speedgrader with them and go through how the grade feedback given in the comments is related to their code far outweighs the work needed to do to rename the students' files (although, given that Canvas' file preview - including in the Speedgrader - does not always display the correct contents of plain-text documents, it makes me question whether I should even be doing this).
Often my students are turning in just one or two files, so having them zip one or two files and handing in the zip file seems like it would add a layer of frustration for both the students and me and my TAs (trying to give them directions on how to zip files). As it is, I still run into students who create a file in one program and then just change the extension so that it will be accepted by Canvas (I once had a student do their work on a sheet of paper, scan it to pdf, open the pdf and copy-paste into Word, and then change the extension to .txt and hand it in). In a class of 50 students, if just 5% of your students have difficulties with this, that's 2, maybe 3, students, but in a class of 500 that's 25 students needing extra help.
It would have been immensely helpful if the Canvas designers had decided to use an underscore ( _ ) instead of a minus sign ( - ) in the renaming scheme: it would mean that the file names (without the extension) would at least be legal identifiers in languages like Java, C, C++, Matlab so they could at least have the potential of being compiled and run as is.
@hasti ,
Were you able to find an answer to your question? I am going to go ahead and mark this question as answered because there hasn't been any more activity in a while so I assume that you have the information that you need. If you still have a question about this or if you have information that you would like to share with the community, by all means, please do come back and leave a comment. Also, if this question has been answered by one of the previous replies, please feel free to mark that answer as correct.
Robbie
No, I definitely have not been able to get an answer to either question. I am willing to assume the answer to question 1 is: no. But to assume the second question has been addressed at all is not correct.
Since Canvas is going to mark this assumed answered otherwise, let me post the results:
Question 1: No one has any idea if this feature can be turned off.
Question 2: No one knows (or is willing to say) whether Canvas has been consistent in its naming techniques.
> there hasn't been any more activity in a while
There was no more activity because nobody responded to hasti's followup. It's a handy way to mark an issue closed - just stop responding to it and say "Oh, looks like nobody has responded so I guess we're good - but hardly a positive way to make people feel heard.
Community helpTo interact with Panda Bot, our automated chatbot, you need to sign up or log in:
Sign inTo interact with Panda Bot, our automated chatbot, you need to sign up or log in:
Sign in
This discussion post is outdated and has been archived. Please use the Community question forums and official documentation for the most current and accurate information.