Skip to content

[Bugfix:Submission] Fix Download Button#12919

Merged
bmcutler merged 5 commits into
mainfrom
fix-quiz-download-button
Jun 19, 2026
Merged

[Bugfix:Submission] Fix Download Button#12919
bmcutler merged 5 commits into
mainfrom
fix-quiz-download-button

Conversation

@dandrecollins07-ctrl

Copy link
Copy Markdown
Contributor

Why is this Change Important & Necessary?

Fixes #10528 Notebook gradeables that only contain text-based responses (such as multiple choice and short answer questions) were displaying a "Download all files" button despite having no user-uploaded files available for download. This also resulted in an empty Submitted Files section being displayed on the submission page.

What is the New Behavior?

If a student submits a quiz/assignment that required no file to be uploaded, they no longer see the option to 'Download all files' or see a 'Submitted Files' bar.

Notebook gradeables with uploaded files and standard homework gradeables continue to behave as before.

Prior to fix:
image

image

After fix:

image

What steps should a reviewer take to reproduce or test the bug or new feature?

On the main branch submit a quiz/notebook assignment with more than one non-file assignment. You will notice that there will be a Download all files, which simply provides an empty zip file.

On the PR branch if you submit a quiz/notebook assignment with more than one non-file assignment. There is no longer the option to Download all files.

Automated Testing & Documentation

N/A

Other information

N/A

@codecov

codecov Bot commented Jun 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 21.45%. Comparing base (2bb39b3) to head (06ff424).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff            @@
##               main   #12919   +/-   ##
=========================================
  Coverage     21.45%   21.45%           
  Complexity     9896     9896           
=========================================
  Files           268      268           
  Lines         36967    36967           
  Branches        495      495           
=========================================
  Hits           7933     7933           
  Misses        28543    28543           
  Partials        491      491           
Flag Coverage Δ
autograder 21.32% <ø> (ø)
js 2.01% <ø> (ø)
migrator 100.00% <ø> (ø)
php 20.49% <ø> (ø)
python_submitty_utils 80.08% <ø> (ø)
submitty_daemon_jobs 91.13% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@NicholasCiuica NicholasCiuica left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tested this PR and have reviewed the code and it looks good to me, I approve it. I just added one comment for potentially improving the comments in the changed file.

To test it, I went on main, made a quiz with one multiple-choice question and made a submission, and saw that the "Submitted Files" section was there. When I added a second question and submitted again, I saw the "Download all files" button. Then I switched to the PR branch and saw that the "Submitted Files" section was not there at all for the quiz submission. While on the branch I double-checked and saw that this PR does not affect the behavior of regular file-submission gradeable.

Comment thread site/app/templates/submission/homework/CurrentVersionResults.twig
@github-project-automation github-project-automation Bot moved this from Seeking Reviewer to Awaiting Maintainer Review in Submitty Development Jun 17, 2026
@bmcutler
bmcutler merged commit d1394d5 into main Jun 19, 2026
32 of 50 checks passed
@github-project-automation github-project-automation Bot moved this from Awaiting Maintainer Review to Done in Submitty Development Jun 19, 2026
@bmcutler
bmcutler deleted the fix-quiz-download-button branch June 19, 2026 18:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Download all files button shows up even when there are no files

3 participants