Project

General

Profile

Actions

action #176214

closed

coordination #154768: [saga][epic][ux] State-of-art user experience for openQA

coordination #154771: [epic] Improved test developer user experience

Re-add detailed error reporting to all AJAX events in openQA webui size:S

Added by dheidler about 2 months ago. Updated about 1 month ago.

Status:
Resolved
Priority:
Low
Assignee:
Category:
Regressions/Crashes
Target version:
Start date:
2025-01-27
Due date:
% Done:

0%

Estimated time:

Description

Observation

In #166310, all the jquery $.ajax() calls were replaced by fetch(), which makes the error reporting a bit trickier when indicating an error via both http status code and error field in the JSON response.

Currently - when the server returns an error - only something like this is e.g. shown when saving a needle and there is an issue with the git push on the server:

Of course this is what it actually should look like (the information is actually sent in the JSON error field):

This is due to the fact that in the current logic first the HTTP Status code is evaluated and if it is not 2xx, only the Status text (empty in this case) is shown but not the json error.
While we could also make better use of the status text, we should fix all the fetch() calls.

I created https://github.com/os-autoinst/openQA/pull/6139 to show how it can be done for saving a needle, but this needs to be applied to all the fetch/fetchWithCSRF calls.
Look at the old PR from #166310 (https://github.com/os-autoinst/openQA/pull/5925) to see all the places where fetch/fetchWithCSRF was added.

Acceptance Criteria

  • AC1: The web UI shows the error message from the server json even if the response status code is 5xx.

Suggestions


Files


Related issues 1 (0 open1 closed)

Related to openQA Project (public) - action #166310: Replace jquery ajax calls with fetch API size:MResolveddheidler2024-09-04

Actions
Actions #1

Updated by dheidler about 2 months ago

  • Related to action #166310: Replace jquery ajax calls with fetch API size:M added
Actions #2

Updated by dheidler about 2 months ago

  • Description updated (diff)
Actions #3

Updated by okurz about 2 months ago

  • Target version set to future
  • Parent task set to #154771
Actions #4

Updated by dheidler about 2 months ago

  • Description updated (diff)
Actions #5

Updated by dheidler about 2 months ago

  • Description updated (diff)
Actions #6

Updated by okurz about 2 months ago

  • Priority changed from Normal to Low
  • Target version changed from future to Ready
Actions #7

Updated by livdywan about 2 months ago

  • Subject changed from Re-add detailed error reporting to all AJAX events in openQA webui to Re-add detailed error reporting to all AJAX events in openQA webui size:S
  • Description updated (diff)
  • Status changed from New to Workable
Actions #8

Updated by dheidler about 2 months ago

  • Assignee set to dheidler
Actions #9

Updated by dheidler about 2 months ago

  • Status changed from Workable to In Progress
Actions #10

Updated by dheidler about 2 months ago

  • Description updated (diff)
Actions #11

Updated by dheidler about 2 months ago

  • Status changed from In Progress to Feedback
Actions #12

Updated by okurz about 1 month ago

  • Status changed from Feedback to In Progress
Actions #13

Updated by dheidler about 1 month ago

  • Status changed from In Progress to Resolved
Actions

Also available in: Atom PDF