Bug 805248

Summary: bugzilla cli should batch all modify commands
Product: [Fedora] Fedora Reporter: Ales Zelinka <azelinka>
Component: python-bugzillaAssignee: Will Woods <wwoods>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: crobinso, jskarvad, wwoods
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-16 15:35:29 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ales Zelinka 2012-03-20 17:56:29 UTC
Description of problem:
When both --assignee and qa_contact are specified, only the assignee gets updated:

$ bugzilla modify --assignee="jhrozek" --qa_contact="jmarko" 799427
$ bugzilla modify --assignee="jhrozek" --qa_contact="jmarko" 799427
$ bugzilla modify  --qa_contact="jmarko" 799427

If you check history of the bug, you'll see only two records. This is what happened:

1st bugzilla call: with both assignee and qa_contact updated the assignee
2nd call: again with both assignee and qa_contact did nothing
3rd call: now including only qa_contact finally updated the qa_contact field (I had to workaround BZ#805245 in order to run bugzilla like that)

Version:
python-bugzilla-0.6.2-2.el6.noarch (f16 srpm rebuilt on rhel6.2, ran against RH bugzilla)

Comment 1 Cole Robinson 2012-12-28 03:05:55 UTC
This is a larger problem in that the CLI only intends to allow one action per 'modify' invocation, but breaks it in various ways since some actions also set a comment, and some of those ignore the private flag, and some others ignore comments altogether :/ So this needs some work

We should have a build_update option similar to build_query that just sums up all the flags the user passed and does it in one shot.

Comment 2 Cole Robinson 2013-01-02 13:21:14 UTC
Upstream now behaves how I suggested in comment #1

Comment 3 Cole Robinson 2013-02-16 15:35:29 UTC
Fixed in python-bugzilla-0.8.0-1.fc19