nus-cs2103-AY2425S1 / pe-dev-response

0 stars 0 forks source link

Duplication handling for add product is not advertised #801

Open nus-se-script opened 3 days ago

nus-se-script commented 3 days ago

Steps to reproduce: 1) Type in add_product n/water

Output: Product is successfully added. image.png

2) Then type in add_product n/WATER

Output: Command box displays an error saying product already exists. image.png

It seems like the application does perform some sort of duplicate handling here since water and WATER are deemed as the same product. However, that behaviour is not advertised anywhere in the UG. Therefore, it is misleading for users as they are not told how duplicates are checked and handled.

I have tagged this as medium because in the real world product names are generally case sensitive. Therefore, to handle such inputs via (I assume to be case insensitive duplicate handling) can prevent users from adding products that may have the similar brand names, with differences in its formatting.


[original: nus-cs2103-AY2425S1/pe-interim#1130] [original labels: severity.Medium type.FeatureFlaw]

yu7ong commented 3 days ago

Team's Response

Justification for Severity.low: Rare likelihood of case-sensitive product names It is unlikely that businesses or users would intentionally use case-sensitive product names to differentiate between items (e.g., water and Water as separate products). This is not a standard practice in real-world inventory systems. Example: Even brands with specific capitalization styles (e.g., iPhone) are usually recognized case-insensitively in systems.

The course website suggests that duplicate detection should account for likely scenarios where two entries are functionally the same despite minor formatting differences (e.g., case differences). Similar to John Doe vs. john doe being likely the same person, water vs. WATER is also likely the same product.

image.png

While the UG does not explicitly mention case-insensitive duplicate handling, this does not lead to a major inconvenience for users. Instead, it prevents potential accidental duplicates, aligning with best practices. Indeed, the UG will be better if updated in future versions to clarify the behavior.

Duplicate status (if any):

--