Bug 814712 - Cannot get bug flags in Bug::search call
Summary: Cannot get bug flags in Bug::search call
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Bugzilla
Classification: Community
Component: WebService
Version: 4.2
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: 4.2-1
Assignee: Simon Green
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: BZ42
TreeView+ depends on / blocked
 
Reported: 2012-04-20 13:56 UTC by Martin Kosek
Modified: 2018-12-09 06:29 UTC (History)
2 users (show)

Fixed In Version: 4.2.1-0.b27
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-04-24 06:04:56 UTC
Embargoed:


Attachments (Terms of Use)

Description Martin Kosek 2012-04-20 13:56:55 UTC
Description of problem:

With 3.6.x Bugzilla version we were able to search bugs and get the respective flags. This is important for us, because we can get all bugs that are of our interest along with their flags (which are further processed) in one call.

Getting a list of bugs via Bug::search call and then requesting flags via Flags::get would decrease the speed of our application and lower user experience.

XMLRPC call with 3.6.x Bugzilla:
$ python
...
>>> print proxy.Bug.search({'bug_status' : ['NEW'], \
                            'product': 'Red Hat Enterprise Linux 6', \
                            'component': 'ipa', \
                            'column_list' : ['id', 'flags']})
{'displaycolumns': ['flags'], 'bugs': [{'bug_id': 689021, 'product': 'Red Hat Enterprise Linux 6', 'flags': 'pm_ack?, rhel-6.4.0?'}, ...

I can no longer get Bugzilla flags with Bugzilla 4.2 because "column_list" is deprecated and "include_fields" does not recognize "flags" field.


Version-Release number of selected component (if applicable):
4.2.0-0.b25

How reproducible:


Steps to Reproduce:
1. Call Bug::search with "include_fields = ['id', 'flags']"
2.
3.
  
Actual results:
Call returns just a list of IDs

Expected results:
Call returns both Bug IDs and flags in the list.

Additional info:

Comment 1 Simon Green 2012-04-23 07:19:11 UTC
Filed upstream with a patch
https://bugzilla.mozilla.org/show_bug.cgi?id=747841

Will work on getting this into our code tomorrow. We need to make some modifications from upstream because (a) we restrict flag visibility, and (b) if you are not logged in, you only see the name of the flag setter and requestee, not their login.

  -- simon

Comment 2 Simon Green 2012-04-24 06:04:56 UTC
Upstream rejected my patch as this change has already been made (by dkl no less) in trunk. I have back ported that code with our extensions to maintain compatibility with Bugzilla 4.4 (assuming there is no change between now and feature freeze of 4.4)

  -- simon


Note You need to log in before you can comment on or make changes to this bug.