dicoogle icon indicating copy to clipboard operation
dicoogle copied to clipboard

"Image Not Found" in image preview is misleading

Open Enet4 opened this issue 4 years ago • 0 comments

When an error occurs while attempting to create a preview of the image, the web application will only report "Image Not Found".

Capture-dicoogle-image-not-found

However, there may be multiple reasons for why Dicoogle is unable to provide a quick preview (either via the thumbnail or by pressing the Show Image button).

  1. The image was indexed, but was no longer found in storage at the time of the preview
  2. The image is in an unsupported encoding, making Dicoogle unable to construct the preview

In case 1 the information would be OK, but in case 2 the message given to the end user is still "Image Not Found", which is very misleading (relevant question on learning pack: bioinformatics-ua/dicoogle-learning-pack#24).

Acceptance criteria:

  • At the server application, ensure that the image service returns different output to distinguish these two kinds of errors.
    • Preferably in a JSON object
  • At the webapp, use that information to show an image providing a more accurate error message
    • For instance, a failure like in case 2 should show something like "Could not create preview"

Enet4 avatar Oct 11 '21 10:10 Enet4