From d80ba1856aa55ff3d222d4738ebc025211b26e8f Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Wed, 4 Feb 2026 12:45:38 +0100 Subject: [PATCH] :sparkles: Add several improvements to frontend error reporting * :sparkles: Add major improvement on error handling * :sparkles: Add the ability to store frontend reports * :paperclip: Add PR feedback changes --- backend/resources/app/templates/base.tmpl | 1 - .../resources/app/templates/error-list.tmpl | 40 ++-- .../app/templates/error-report.v3.tmpl | 2 +- .../app/templates/error-report.v4.tmpl | 46 ++++ backend/resources/app/templates/styles.css | 22 +- backend/src/app/http/debug.clj | 27 ++- backend/src/app/http/errors.clj | 2 +- backend/src/app/loggers/audit.clj | 81 +++---- backend/src/app/loggers/database.clj | 189 ++++++++++------ backend/src/app/loggers/mattermost.clj | 137 ++++++++---- backend/src/app/main.clj | 8 +- backend/src/app/migrations.clj | 5 +- .../0144-mod-server-error-report-table.sql | 4 + backend/src/app/rpc/commands/audit.clj | 100 ++++++--- backend/test/backend_tests/helpers.clj | 8 + common/src/app/common/exceptions.cljc | 65 +++++- frontend/src/app/main/errors.cljs | 207 ++++++++---------- .../src/app/main/ui/dashboard/import.cljs | 4 +- frontend/src/app/main/ui/static.cljs | 18 +- frontend/src/debug.cljs | 6 +- frontend/translations/en.po | 2 +- 21 files changed, 611 insertions(+), 363 deletions(-) create mode 100644 backend/resources/app/templates/error-report.v4.tmpl create mode 100644 backend/src/app/migrations/sql/0144-mod-server-error-report-table.sql diff --git a/backend/resources/app/templates/base.tmpl b/backend/resources/app/templates/base.tmpl index 893b6bc066..7c85c4e40f 100644 --- a/backend/resources/app/templates/base.tmpl +++ b/backend/resources/app/templates/base.tmpl @@ -5,7 +5,6 @@ {% block title %}{% endblock %} - diff --git a/backend/resources/app/templates/error-list.tmpl b/backend/resources/app/templates/error-list.tmpl index c328700ecf..3008acda9c 100644 --- a/backend/resources/app/templates/error-list.tmpl +++ b/backend/resources/app/templates/error-list.tmpl @@ -5,23 +5,25 @@ penpot - error list {% endblock %} {% block content %} - -
- -
+ +
+ +
{% endblock %} diff --git a/backend/resources/app/templates/error-report.v3.tmpl b/backend/resources/app/templates/error-report.v3.tmpl index 0892e77b34..a3eddfaa86 100644 --- a/backend/resources/app/templates/error-report.v3.tmpl +++ b/backend/resources/app/templates/error-report.v3.tmpl @@ -6,7 +6,7 @@ Report: {{hint|abbreviate:150}} - {{id}} - Penpot Error Report (v3) {% block content %}