Project

General

Profile

Actions

action #89638

closed

libyui-rest-api does not report errors when querying wrong widgets, and debug labels cannot be query'd.

Added by JRivrain about 3 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Start date:
2021-04-12
Due date:
% Done:

100%

Estimated time:

Description

If we run a query like http://server:port/v1/widgets?debug_label=SomeText, it returns a json like the one attached (widgets.json, see also the corresponding dialog.json, those come from the "welcome" firstboot client) . So at first sight it looks like the query worked. But In fact, it is the same as querying "http://server:port/v1/widgets" without any arguments. We can observe the same with other elements, that are not "query-able" or non-existant (eg "widgets?class=YQWizardButton" or "widgets?notexist=nope").
It would make more sense to have a "widget-not-found" error in such cases.

Also, being able to query those debug_labels to identify pages could be very useful, as there is no (?) other unique way to identify pages/modules/clients otherwise, and those seem to be present on each of them.

https://github.com/libyui/libyui-rest-api was included into https://github.com/libyui/libyui and is a sub-directory.


Files

dialog.json (2.87 KB) dialog.json JRivrain, 2021-03-08 17:25
widgets.json (1.67 KB) widgets.json JRivrain, 2021-03-08 17:25
Actions

Also available in: Atom PDF