nus-cs2103-AY2021S2 / pe-dev-response

0 stars 0 forks source link

Inconsistent error message for indexes provided to command #3116

Open nus-pe-bot opened 3 years ago

nus-pe-bot commented 3 years ago

For example, let's assume the current student list size is 10

when commands require STUDENT_INDEX as an argument, eventhough 11 and 0 are both indexes / integer, 0 will throw invalid command format! while 10 will throw The student index provided is invalid While in delete_session, giving 0 will throw Index is not a non-zero unsigned integer.

image.png

image.png

image.png


[original: nus-cs2103-AY2021S2/pe-interim#3116] [original labels: severity.Low type.FunctionalityBug]

chwoozy commented 3 years ago

Team's Response

We have made this issue Very Low, as we consider this a cosmetic issue (different ways of showing the error to the User).

In terms of the error message shown, they are all valid and differ because they are non-uniform different errors.

  1. delete_student 11 is indeed a invalid number, not an invalid format. Thus, a different error from the other 2.
  2. delete_student 0 shows a correct error as in "INDEX (must be a positive integer)"
  3. This is a prompt for non-zero unsigned integer.

As such, the 2 error messages that should perhaps be similar in its format as you suggest, are primarily 2 and 3. Altogether, it is a cosmetic issue. Thank you for your suggestion

Duplicate status (if any):

--