[python-bugzilla] How to needinfo certain email

Cole Robinson crobinso at redhat.com
Wed Jul 2 13:49:36 UTC 2014


On 07/01/2014 05:02 AM, Shaolong Hu wrote:
> Hi,
> 
> I am wondering how to needinfo certain email, i find "update_flags":
>         '''
>         Updates the flags associated with a bug report.
>         Format of flags is:
>         [{"name": "needinfo", "status": "+", "requestee": "foo at bar.com"},
>          {"name": "devel_ack", "status": "-"}, ...]
>         '''
> But seems {"name": "needinfo", "status": "?", "requestee": "foo at bar.com"} only
> gives a "foo:needinfo?", how to construct flag to give a
> "fooA:needinfo?(fooB at bar.com)" ?

I just tried this:

import bugzilla

bzapi = bugzilla.Bugzilla("partner-bugzilla.redhat.com")
print bzapi.update_flags("1000000", [{
    "name": "needinfo",
    "status": "?",
    "requestee": "crobinso at redhat.com"}])

And it worked as expected, generating a this line:  	crobinso: needinfo?
(crobinso)

Probably only works for a valid RH account, so if you actually tried
foo at bar.com it might fail.

- Cole



More information about the python-bugzilla mailing list