E1863 Issues related to assignment creation
Introduction
An instructor or TA can create assignments within a course. There are a lot of configurations that can be made while creating these assignments and there are a few known issues related to this.
Problem statement
There are 5 issues that are being dealt with in this project:
There are assignments that have rubrics that vary by round, i.e. each round of the assignment review will have a different set of rubrics. When such an assignment is copied, there exists a problem where the rubrics from the original assignment are not copied over properly to the new assignment. This new assignment does not have rubrics that vary by round, as in the original assignment, but have the rubric from Round 1 in the original assignment copied over for all rounds. This makes the copying of assignments incomplete and thus, needs to be fixed.
While creating/editing an assignment, one of the configurations is setting up of the rubrics. This is done in the 'Rubrics' tab of the assignment page. While setting up the rubrics, we can assign a weight to each of it, so that the final score will be the weighted sum of the different rubric scores. The default weight of a rubric is always 0%, meaning that it's not counted towards the final score. But if any of the rubric is assigned with a non-zero weight, we need to make sure that the sum of all the weights of the various rubrics add up to 100%. This is not enforced currently, allowing the user to have a total weight which is between 0% and 100%. This needs to be fixed to bring in a hard stop, if the sum of the weights don't add up to 0% or 100%.
Proposed Solution
When we save a new/existing assignment, we need to bring in a check to see if the sum of the weights of the various rubrics add up to 0 or 100%. If this check fails, we need to throw a notice that says, "Sum of weights of rubrics need to be 0 or 100%.". The user has to make the corresponding modification to the weights and try again. If the check succeeds, we continue with the assignment saving process.