On 02/16/2017 01:44 PM, Dennis Kliban wrote:
I have some code that looks very similar to what I have below.
from bugzilla.rhbugzilla import RHBugzilla
BUGZILLA_URL = 'https://bugzilla.redhat.com'
BZ = RHBugzilla(url='%s/xmlrpc.cgi' % BUGZILLA_URL, user=user,
password=password)
bugzilla_bugs = BZ.query(RHBugzilla.url_to_query(non_closed_bug_with_ext_tracker))
for bug in bugzilla_bugs:
for external_bug in bug.external_bugs:
print external_bug
This works fine with python-bugzilla 1.2.2, but when switching to 2.0.0, I get
an exception like this:
Traceback (most recent call last):
File "pulp_packaging/ci/redmine_bugzilla.py", line 242, in <module>
main()
File "pulp_packaging/ci/redmine_bugzilla.py", line 193, in main
for external_bug in bug.external_bugs:
File "/usr/lib/python2.7/site-packages/bugzilla/bug.py", line 110, in
__getattr__
raise AttributeError(msg)
AttributeError: Bug object has no attribute 'external_bugs'.
Does anyone have a suggestion for how to fix my script?
Hmm, not sure, can you send me the specific query you are using and a link to
the code? Off list if you prefer
Thanks,
Cole