Open mitchmalvin1 opened 1 year ago
No details provided by team.
[The team marked this bug as a duplicate of the following bug]
Certain words are ignored input
Input:
add [RANDOM WORDS] /q [QUESTION] /a [ANSWER]
add
can be replaced with clear, help, review, byeExpected:
The input is in an incorrect format. You can view our user guide or type help to see the correct formats for commands. ==========================================================
Actual:
You have added the following card: Q:[QUESTION] A:[ANSWER] ==========================================================
Proof:
Cases where extra words are not ignored:
list all [RANDOM WORDS]
Apologies if this is an intended behaviour.
[original: nus-cs2113-AY2223S2/pe-interim#2026] [original labels: severity.Low type.FeatureFlaw]
[This is the team's response to the above 'original' bug]
It is the intended behavior for the program to ignore the text not behind any option function (eg: /q). I believe that our user guide already indicates that when adding a question by
add /q QUESTION /a ANSWER
, onlyQUESTION
andANSWER
would be recorded into the system.The program tries its best to recover from user mistakes, by ignoring options that are not relevant to its operation, instead of throwing completely and forcing the user to retype. It doesn't allow typo so you can't get away with
reviuw
but it will ignore arguments it don't care if they exist, and that's entirely by design.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]
When the user runs
card add d -q QN -a ANS
, the extra d after the add is uncaught and the card is still added. This is definitely undefined behaviour as the UG only mentions that duplicated options will be ignored except the last but did not say anything about arguments that do not belong to any options like thed
in the command above.