minvws / nl-kat-coordination

Repo nl-kat-coordination for minvws
European Union Public License 1.2
123 stars 55 forks source link

User friendly error pages in production #2710

Open stephanie0x00 opened 5 months ago

stephanie0x00 commented 5 months ago

Describe the bug Currently when OpenKAT gives an error (eg 404/500 etc) and shows a blank page with just the error number as shown below. This is not very user friendly as a non-technical user would likely not know how to navigate back using the URL bar.

To Reproduce Steps to reproduce the behavior:

  1. Change to production by adding DEBUG=False to your .env file
  2. Run make kat.
  3. Go to a non-existing page in your browser and see the error message.

Expected behavior As a user I'd expect to see a KAT-like interface with the error message.

When I trigger a error message I either redirect to the home-page of KAT or get an error page with the KAT task bar and obviously an image of a cat somewhere with a message that you have to check your log files. Some inspiration cat:

 Cats Knocking Things Over

Screenshots image

OpenKAT version commit 0b76da4b04696855d1f3a300eb6d292dc9717b57 (HEAD -> main, origin/main, origin/HEAD)

underdarknl commented 5 months ago

https://docs.djangoproject.com/en/5.0/topics/http/views/#customizing-error-views

underdarknl commented 5 months ago

@HeleenSG can you think of a nice graphic that shows something went wrong? Maybe a spilled cat's food-tray with a sad kat next to it?

NoemiOverdijk commented 5 months ago

I did actually make a sketch for this a long time ago based on existing KAT illustrations (made by Wouter)

Image Image

You can also find them here: https://www.figma.com/file/NRpwbMYdatiOL2dsF7oqWp/%F0%9F%A7%B1-KAT-%7C-Workfile-%7C-Components?type=design&node-id=527%3A21&mode=design&t=AckEo2GFqMmS3WM3-1