Closed bernhardreiter closed 4 years ago
If there is a backend problem it should be visible without scrolling. Right now there is no area that is visible all times. So we have two possible solutions:
Right now there already is a general place which is a working animation if an API call takes too long. This is done in the upper menu bar. This could be a good default place.
A grep '$http' -r
shows all places where the vue-resource
function is called. We have 15 places. Some of them are close enough together be use one display element for their joined status messages.
9f23e5678ba42fd2b99ad4541e847d4b372f33e9 adds a general backendProblem display area in the navigation bar as proof of concept. The problem with this is, when it should be cleared, if we have several request on a subpage.
If we have several requests possibilities per page, the general place solution would only work, if we'd track the status for each possible connection for the display. This can have advantages if it is three times the same problem, but it is close to introducing a global state of the backend, which is even more work.
So I'll try the "2. close to individual elements" solution next.
To create some error messages from the backend for testing:
import time
, time.sleep(10)
or so to the endpointno: int
-> 400 from hugfrom falcon import HTTP_BAD_REQUEST, HTTP_NOT_FOUND
, getting the response
from the endpoint function definition and then response.status = HTTP_BAD_REQUEST; return {"reason": "DataError, probably not in cidr style."}
, see https://falcon.readthedocs.io/en/stable/api/status.htmlresponse
object from the endpoint function and then response.body = '{abc' ; return
Here is can be seen that the reason for a backend call failure is shown for tickets.
And if no events for a ticket are found, this is different now:
Status with work from last week committed now.
Some illustrating screenshots
(Note the backend does not (yet) give more information in this commit case.)
There are several different kind of problems with calling the fody-backend:
While #29 is more specific to commit problems (with is the third class of issues), there also should be a method to display general problems in all section of the backend to the user.
technical ideas:
Use the notification style in the navigation bar of the copilot template?
Or display it closer to the the place where the user is looking (in case of contacts this would be either the search field like the results limitation or close to the commit button).