chanzuckerberg / cryoet-data-portal

CryoET Data Portal
MIT License
16 stars 9 forks source link

Improve error pages in web GUI with prefixed IDs #1009

Open kandarpksk opened 1 month ago

kandarpksk commented 1 month ago

Alongside design updates for prefixed IDs in the web GUI, let's also improve the error page that users might see if they use the prefixed ID in URLs. For example: https://cryoetdataportal.czscience.com/datasets/DS-10083 shows: 400 ID is not defined

Let's use this issue to discuss the phrasing async. I'm thinking there could be dedicated messages when:

(These are first drafts for the message part, I don't know how best to show the HTTP 400 error code)

cc: @junxini @kev-zunshiwang @dgmccart

kandarpksk commented 2 weeks ago

FWIW, there is a better message we show when the dataset ID entered is numeric, but does not exist. For example, https://cryoetdataportal.czscience.com/datasets/10500 shows:

404 Dataset with ID 10500 not found

Maybe there's potential to keep them consistent for such cases.