Allow API to return inactive custom fields including old tracking flags
Categories
(bugzilla.mozilla.org :: API, enhancement)
Tracking
()
People
(Reporter: kohei, Assigned: kohei)
References
(Blocks 1 open bug)
Details
Somehow nobody has filed or noticed this bug, but as :marco pointed out on IRC, the current /rest/bug
API doesn’t return inactive custom fields like cf_status_firefox33
even if it’s set. Maybe we could add a new filter like include_fields=custom_all
that returns all the fields including old ones.
https://github.com/mozilla-bteam/bmo/blob/master/Bugzilla/WebService/Bug.pm#L1526
Comment 1•5 years ago
|
||
(In reply to Kohei Yoshino [:kohei] (Bugzilla UX) (FxSiteCompat) from comment #0)
Somehow nobody has filed or noticed this bug, but as :marco pointed out on IRC, the current
/rest/bug
API doesn’t return inactive custom fields likecf_status_firefox33
even if it’s set. Maybe we could add a new filter likeinclude_fields=custom_all
that returns all the fields including old ones.https://github.com/mozilla-bteam/bmo/blob/master/Bugzilla/WebService/Bug.pm#L1526
That'd be include_fields=_custom_all, which (in the active_custom_fields hook) $wants->type->{custom_all}
Assignee | ||
Comment 2•5 years ago
•
|
||
Well, we need to rename active_custom_fields
😆
An example :marco mentioned is Bug 1042192, which has flags for Firefox 32, 33 and 34.
They don’t show up in https://bugzilla.mozilla.org/rest/bug?id=1042192&include_fields=_custom (search)
but they do show up in https://bugzilla.mozilla.org/rest/bug/1042192?include_fields=_custom (specific bug)
Comment 3•5 years ago
|
||
I can get status65 when getting info for a given bug:
curl "https://bugzilla.mozilla.org/rest/bug/1511433?include_fields=cf_status_firefox68&include_fields=cf_status_firefox65"
=> {"bugs":[{"cf_status_firefox68":"fixed","cf_status_firefox65":"affected"}],"faults":[]}
but when searching, the result is different:
curl "https://bugzilla.mozilla.org/rest/bug?bug_id=1511433&include_fields=cf_status_firefox68&include_fields=cf_status_firefox65"
=> {"bugs":[{"cf_status_firefox68":"fixed"}]}
but in adding id:
curl "https://bugzilla.mozilla.org/rest/bug/1511433?include_fields=cf_status_firefox68&include_fields=cf_status_firefox65&include_fields=id"
{"bugs":[{"cf_status_firefox68":"fixed","cf_status_firefox65":"affected","id":1511433}],"faults":[]}
my failing query is (status65 is missing):
curl "https://bugzilla.mozilla.org/rest/bug?f1=status_whiteboard&product=Core&product=DevTools&product=External+Software+Affecting+Firefox&product=Firefox&product=Firefox+for+Android&product=Firefox+Build+System&product=Testing&product=Toolkit&product=WebExtensions&bug_id=1511433&v1=%5Bno-nag%5D&include_fields=cf_status_firefox68&include_fields=cf_status_firefox65&include_fields=id&include_fields=summary&include_fields=groups&o1=notsubstring"
=> {"bugs":[{"cf_status_firefox68":"fixed","summary":"Artifacts and flickering when rendering gradients on webrender on android","groups":[],"id":1511433}]}
this is very weird...
Assignee | ||
Comment 4•5 years ago
|
||
Yeah, weird enough, I cannot reproduce the issue locally. Both a specific bug and bug search return the same results, rather including all the inactive tracking flags by default. I guess it’s a caching issue still handled in Bug 1508695.
Description
•