InstituteforDiseaseModeling / malaria-model_validation

1 stars 2 forks source link

Better error handling when site result is not available or certain image file is not available. #56

Closed YeChen-IDM closed 1 year ago

YeChen-IDM commented 1 year ago

Right now, if a dataframe is empty, the plotting code will give an attribute error saying the "Infection" (for example) is not found, this is not informative error. In PR #53 I updated to skip the plotting code if a certain site result is not available. Should we raise a more informative error in such case?

We need to make similar decision and change in the reporting code when a table or image file is not there. In PR #53, I updated the code to ignore the table/image if it's not found and print a warning message. Do we want to throw exception and let the workflow fails in such case?

YeChen-IDM commented 1 year ago

after discussing with @MAmbrose-IDM, we decided to add an "image not found" image if a certain image is not available to inform the end user in the final report.

YeChen-IDM commented 1 year ago

Done with #59