Bug 823544 - Stack trace modifying bugs with latest bugzilla.redhat.com (4.2.1)
Summary: Stack trace modifying bugs with latest bugzilla.redhat.com (4.2.1)
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: python-bugzilla
Version: el6
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Will Woods
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 823455 823495 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-05-21 13:44 UTC by mkovacik
Modified: 2013-01-10 06:47 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-12-30 22:06:47 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description mkovacik 2012-05-21 13:44:55 UTC
Description of problem:
A stack trace happens trying to update a bug. Creating new bugs seems to work, though. See Additional info for the stack trace...

Version-Release number of selected component (if applicable):
0.6.2 (bugzilla.redhat.com: 4.2.1)  

How reproducible:
Always

Steps to Reproduce:
1. create a bug with python-bugzilla
2. try to update it with python-bugzilla
3. a stack trace happens
  
Actual results:
Updating bugs doesn't work anymore with bugzilla.redhat.com (version 4.2.1)

Expected results:
Updating bugs on bugzilla.redhat.com works

Additional info:
## STACK TRACE
## called from within a custom bash script as:
##   bugzilla modify $BUGZILLA -l "${BUG_COMMENTS}"

Traceback (most recent call last):
  File "/root/valid/src/bugzilla-command", line 682, in <module>
    main()
  File "/root/valid/src/bugzilla-command", line 543, in main
    buglist = bz.getbugssimple(bugid_list)
  File "/root/valid/src/bugzilla/base.py", line 528, in getbugssimple
    return [(b and _Bug(bugzilla=self,dict=b)) or None for b in self._getbugssimple(idlist)]
  File "/root/valid/src/bugzilla/bugzilla3.py", line 68, in _getbugs
    bugdict = dict([(b['id'], b['internals']) for b in r['bugs']])
KeyError: 'internals'

Comment 1 mkovacik 2012-05-21 13:57:17 UTC
*** Bug 823495 has been marked as a duplicate of this bug. ***

Comment 2 mkovacik 2012-05-21 13:57:50 UTC
*** Bug 823455 has been marked as a duplicate of this bug. ***

Comment 3 mkovacik 2012-05-22 14:47:26 UTC
Actually, I wasn't using latest version; installing python-bugzilla from epel gets me to this error instead; so what is failing is changing the state of a bug...

##
[root@ip-10-48-83-15 ~]# bugzilla --verbose --debug modify -status="VERIFIED" 823866                                                                                                                                                                                       
INFO:bugzilla:Connecting to https://bugzilla.redhat.com/xmlrpc.cgi
INFO:bugzilla:Autodetecting Bugzilla type
INFO:bugzilla:Bugzilla v0.6.0 initializing
DEBUG:bugzilla:Choosing subclass for https://bugzilla.redhat.com/xmlrpc.cgi
DEBUG:bugzilla:Checking for RH Bugzilla method bugzilla.getProdInfo()
DEBUG:bugzilla:rhbz=True
DEBUG:bugzilla:Checking return value of Buzilla.version()
DEBUG:bugzilla:bzversion='4.2.1-1.1'
INFO:bugzilla:Chose subclass RHBugzilla v0.2
INFO:bugzilla:Using cookies in /root/.bugzillacookies for authentication
DEBUG:bugzilla:request_url is https://bugzilla.redhat.com/xmlrpc.cgi
DEBUG:bugzilla:send_cookies(): using existing cookiejar
DEBUG:bugzilla:cookie_request headers currently: []
DEBUG:bugzilla:cookie_request headers now: [('Cookie', 'Bugzilla_logincookie=tkngRTRIm4; Bugzilla_login=321807')]
DEBUG:bugzilla:sending cookie: Cookie=Bugzilla_logincookie=tkngRTRIm4; Bugzilla_login=321807
DEBUG:bugzilla:cookiejar now contains: {'.bugzilla.redhat.com': {'/': {'Bugzilla_logincookie': Cookie(version=0, name='Bugzilla_logincookie', value='tkngRTRIm4', port=None, port_specified=False, domain='.bugzilla.redhat.com', domain_specified=True, domain_initial_dot=False, path='/', path_specified=True, secure=True, expires=2145916800, discard=False, comment=None, comment_url=None, rest={'HttpOnly': 'None'}, rfc2109=False), 'Bugzilla_login': Cookie(version=0, name='Bugzilla_login', value='321807', port=None, port_specified=False, domain='.bugzilla.redhat.com', domain_specified=True, domain_initial_dot=False, path='/', path_specified=True, secure=True, expires=2145916800, discard=False, comment=None, comment_url=None, rest={'HttpOnly': 'None'}, rfc2109=False)}}}
DEBUG:bugzilla:Bug(['status_whiteboard', 'groups', 'bug_file_loc', 'rep_platform', 'devel_whiteboard', 'short_desc', 'priority', 'version', 'group_names', 'bug_status', 'product', 'qa_contact', 'reporter', 'component', 'bug_severity', 'bug_id', 'delta_ts', 'creation_ts', 'target_milestone', 'target_release', 'alias', 'assigned_to', 'resolution', 'op_sys'])
DEBUG:bugzilla:modifying bug 823866
DEBUG:bugzilla:  set status: tatus=VERIFIED
Traceback (most recent call last):
  File "/usr/bin/bugzilla", line 655, in <module>
    main()
  File "/usr/bin/bugzilla", line 530, in main
    bug.setstatus(opt.status, opt.comment, private=opt.private)
  File "/usr/lib/python2.6/site-packages/bugzilla/base.py", line 1176, in setstatus
    self.bugzilla._setstatus(self.bug_id,status,comment,private,private_in_it,nomail)
  File "/usr/lib/python2.6/site-packages/bugzilla/rhbugzilla.py", line 209, in _setstatus
    comment,private,private_in_it,nomail)
  File "/usr/lib/python2.6/xmlrpclib.py", line 1199, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib/python2.6/xmlrpclib.py", line 1483, in __request
    allow_none=self.__allow_none)
  File "/usr/lib/python2.6/xmlrpclib.py", line 1132, in dumps
    data = m.dumps(params)
  File "/usr/lib/python2.6/xmlrpclib.py", line 677, in dumps
    dump(v, write)
  File "/usr/lib/python2.6/xmlrpclib.py", line 699, in __dump
    f(self, value, write)
  File "/usr/lib/python2.6/xmlrpclib.py", line 703, in dump_nil
    raise TypeError, "cannot marshal None unless allow_none is enabled"
TypeError: cannot marshal None unless allow_none is enabled
[root@ip-10-48-83-15 ~]#

Comment 4 Cole Robinson 2012-12-30 22:06:47 UTC
This command line is wrong:

bugzilla --verbose --debug modify -status="VERIFIED" 823866       

You are missing a second - before -status and it's causing a weird error.

Either way, the correct command works for me, so closing.


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