neojxuan / pe

0 stars 0 forks source link

App cannot start up with invalid json file content #10

Open neojxuan opened 2 years ago

neojxuan commented 2 years ago

Replacing all content in the json file with null, the app is unable to start up with an empty data file.

nus-pe-bot commented 2 years ago

Team's Response

Duplicate of 1135, where editing the JSON files results in the application not starting. Thank you for your response :)

The 'Original' Bug

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

Editing JSON file for dates results in application not starting

Editing the JSON file such that an end time is before a start time results in the application not starting.

Steps to reproduce:

  1. Edit the JSON file such that the end time is before the start time. image.png
  2. Start app with java -jar .\[CS2103T-T15-1][GoMedic].jar
  3. App throws error and does not start. image.png

[original: nus-cs2103-AY2122S1/pe-interim#1090] [original labels: type.FunctionalityBug severity.Medium]

Their Response to the 'Original' Bug

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

Thank you for the report, we feel that this bug should be low as being able to edit the JSON file might have been a tp constraint but it is not considered as expected user behaviour so the chances of this bug occurring is very low since we expect data in GoMedic to be modified via the app as most users should. Not only that, the error message can be seen in the log files, and we expect the advanced users can make use of these files.

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: 1. Issues are not exactly the same.

  1. These issues can be fixed independently. I believe the problems are caused by different exceptions - one is the NullPointerException since null is not handled while the other is the IllegalArgumentException. I believe even if the IllegalArgumentException were handled by itself, the bug where the app cannot start up when null replaces some content will still occur.

image.png