lihka1202 / pe

0 stars 0 forks source link

Display error not correct #3

Open lihka1202 opened 1 year ago

lihka1202 commented 1 year ago

Based on the interaction with the program:

add -out food $67
Done! Added: out for food, -$67.00, in category miscellaneous on 14/04/2023

This format is appropriate when adding stuff into the inventory

if the amount is exceeded:

add -out food $348750348590480495943
Unsupported amount provided, note that amount has to be a number > 0 and <= 21,474,836.47
Add format is as follows: 
add [-in/-out] [description] $[value] {-c category} {-date DD/MM/YYYY} 
Please refer to 'help' for more information!

This is the error, however if the value of 21,474,836.47 is added, the programs flags this output to be inappropriate

add -out food $21,474,836.47
Sorry, your add command is invalid. Add format is as follows: 
add [-in/-out] [description] $[value] {-c category} {-date DD/MM/YYYY} 
Please refer to 'help' for more information!

Which is an issue internally, and the error message is displaying the wrong information

soc-se-bot commented 1 year ago

Team's Response

This is done delibrately to improve readability, as having an 8-digit number with 2 decimal places without commas will make it difficult to read clearly. Ultimately, this is an aesthetics issue and there is no clear winner in terms of the best way to present it.

Items for the Tester to Verify

:question: Issue response

Team chose [response.Rejected]

Reason for disagreement: Based on the code snippets above, Im using the same ones.

When I entered the following command:

add -out food $67
Done! Added: out for food, -$67.00, in category miscellaneous on 14/04/2023

I received an appropriate response. However, when I entered the same command and replaced 67 with 21,474,836.47, I get the following result.

add -out food $21,474,836.47
Sorry, your add command is invalid. Add format is as follows: 
add [-in/-out] [description] $[value] {-c category} {-date DD/MM/YYYY} 
Please refer to 'help' for more information!

Since I merely replaced the values, and the command with 67 is considered valid, it doesn't make sense for the command listed above to be invalid. Hence I made the claim that the error message displayed has an error. Since the format of the command is right, just that the format of the value is wrong, and this is what needs to be pointed out to the user.


## :question: Issue severity Team chose [`severity.VeryLow`] Originally [`severity.Low`] - [x] I disagree **Reason for disagreement:** This is not an aesthetic issue, hence I believe the severity should remain as it is.