From e16d7750c9f1e754a3e14a496380de0b014fffe1 Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Mon, 29 Jul 2024 16:04:13 -0500 Subject: Provide a generalised way to handle errors and exceptions. --- uploader/templates/unhandled_exception.html | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) (limited to 'uploader/templates/unhandled_exception.html') diff --git a/uploader/templates/unhandled_exception.html b/uploader/templates/unhandled_exception.html index 6e6a051..d6087cb 100644 --- a/uploader/templates/unhandled_exception.html +++ b/uploader/templates/unhandled_exception.html @@ -1,4 +1,5 @@ {%extends "base.html"%} +{%from "flash_messages.html" import flash_all_messages%} {%block title%}System Error{%endblock%} @@ -7,15 +8,17 @@ {%endblock%} {%block contents%} -

- An error has occured, and your request has been aborted. Please notify the - administrator to try and get this sorted. -

-

- Provide the following information to help the administrator figure out and fix - the issue:
-



- {{trace}} -

-

+
+ {{flash_all_messages()}} +

Exception!

+ +

An error has occured, and your request has been aborted. Please notify the + administrator to try and get this fixed.

+

The system has failed with the following error:

+
+
+
+    {{'\n'.join(trace).strip()}}
+  
+
{%endblock%} -- cgit v1.2.3