bingsen0806 / pe

0 stars 0 forks source link

Inaccurate error message when inputting invalid task date #3

Open bingsen0806 opened 2 years ago

bingsen0806 commented 2 years ago

Reproduce: addEvent desc/2103PE at/2022-04-31 1900 2000

Expected: system telling me date is invalid

Actual: system tells me month should be between 1-12 and day should be between 1-31.

It is true that the system recognizes the input is invalid, but the error message is wrong because my month is between 1-12 and day is between 1-31 (i.e. I followed the constraints but still have error message)

image.png

nus-se-bot commented 2 years ago

Team's Response

Reason

This bug report of is a duplicate of #238 because it has been already been reported before in #238, where the error is the same when user input a "valid" date that is actually not valid but the error message thrown is wrong. Furthermore fixing the error message in #238 (changing the error message to be more specific) would also fix this issue.

The 'Original' Bug

[The team marked this bug as a duplicate of the following bug]

Wrong error message for invalid date format

image.png

Error message states "Date should be in the format of yyyy-MM-dd. Year should be greater then 0000, Month should only be between 1 and 12 and Day should only be between 1 and 31." which 2022-02-30 holds.


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

Their Response to the 'Original' Bug

[This is the team's response to the above 'original' bug]

Thank you for finding this bug, we should have been more specific in our error message.

Items for the Tester to Verify

:question: Issue duplicate status

Team chose to mark this issue as a duplicate of another issue (as explained in the Team's response above)

Reason for disagreement: [replace this with your explanation]