Open TY1Fan opened 2 weeks ago
Currently, our app does check for duplicate assignments, preventing assignments from simultaneously having the same name and max score.
It was intended behaviour that assignments with the same names but different max scores should be allowed.
This is because teachers may want to use general names for assignments, but have different maximum scores to distinguish them. This is to allow for more user flexibility while using our app.
For example, a math teacher may want to assign 2 homework assignments, generally titled "Math homework", but with different scores. This should be accepted behaviour as the teacher can already distinguish the assignments based on the maximum scores.
Team chose [response.NotInScope
]
Reason for disagreement: Thank you for agreeing with my view that this feature is flawed. But I feel that there might be some misunderstandings in the issue raised as the dev team is responding to the behavior of the feature when I am not reporting a functionality bug. To clarify, I am reporting a feature flaw on the duplicate handling conditions.
I feel that having a duplicate when the title and max score is not intuitive to the users. While adding an additional condition will improve the flexibility of this feature, I feel that this would, at the same time, bring about more confusion. Just imagine users would have to memorize the max score in order to differentiate the assignments with the same title. In this case, since there is no remarks section for assignments, I feel that it would be better to be more restrictive in the duplicate detection so that users will input an assignment title that is more descriptive and easier for the users to differentiate rather than memorize the max score.
I think would be good to expand on the capability of your duplicate detection to detect same assignment title as well.
Actually what I meant for this line is that the duplicate detection should detect just same titles, irregardless of the max score. I would like to apologize for the lack of clarity on this.
Given my proposed implementation, the effort required to change would be minimal.
/**
* Returns true if both assignments have the same assignmentName.
* This defines a weaker notion of equality between two assignments.
*/
public boolean isSameAssignment(Assignment otherAssignment) {
if (otherAssignment == this) {
return true;
}
return otherAssignment != null
&& otherAssignment.assignmentName.equals(assignmentName)
&& otherAssignment.maxScore == maxScore; // delete this line
}
Since the changes to be made are minimal (prob less than 5 lines), and the dev team also recognized that theres a need to improve on this feature, I feel that this issue should be Accepted
rather than NotInScope
according to the course website.
Screenshot 2024-11-19 at 7.08.19 PM
Steps to reproduce:
add_assignment si/3 an/Assignment 1 ms/100
add_assignment si/3 an/Assignment 1 ms/10000
Expected: Duplicate assignment error to be thrown
Actual: No error
Suggestion/ Why it is problematic: Both are titled assignment 1. This may confuse user as to what is the grade of assignment 1 as they seem to be duplicate assignment with different score. I think would be good to expand on the capability of your duplicate detection to detect same assignment title as well.