#3491 Can't link bodhi update to bug number
Closed: Fixed None Opened 12 years ago by remi.

= bug description =
Where trying to link a bug number to an existing update (pending)

"Update successfully edited. Unable to access one or more bugs. Exception: '/var/tmp/bodhi-bz.cookie' does not look like a Netscape format cookies file"


{{{
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/CherryPy-2.3.0-py2.6.egg/cherrypy/_cphttptools.py", line 121, in _run
self.main()
File "/usr/lib/python2.6/site-packages/CherryPy-2.3.0-py2.6.egg/cherrypy/_cphttptools.py", line 264, in main
body = page_handler(virtual_path, self.params)
File "<string>", line 3, in save
File "/usr/lib/python2.6/site-packages/turbogears/controllers.py", line 361, in expose
*args,
kw)
File "<generated code>", line 0, in run_with_transaction
File "/usr/lib/python2.6/site-packages/peak/rules/core.py", line 153, in call
return self.body(
args, kw)
File "/usr/lib/python2.6/site-packages/turbogears/database.py", line 410, in so_rwt
retval = func(*args,
kw)
File "/usr/lib/python2.6/site-packages/turbogears/controllers.py", line 244, in _expose
@abstract()
File "<generated code>", line 0, in _expose
File "/usr/lib/python2.6/site-packages/peak/rules/core.py", line 153, in call
return self.body(args, kw)
File "/usr/lib/python2.6/site-packages/turbogears/controllers.py", line 255, in <lambda>
False, {}, args, kw))
File "/usr/lib/python2.6/site-packages/turbogears/controllers.py", line 425, in _execute_func
output = errorhandling.try_call(func, *args,
kw)
File "/usr/lib/python2.6/site-packages/turbogears/errorhandling.py", line 77, in try_call
return func(self,
args, kw)
File "<string>", line 2, in save
File "/usr/lib/python2.6/site-packages/bodhi/util.py", line 494, in json_redirect
return f(*args,
kw)
File "<string>", line 3, in save
File "/usr/lib/python2.6/site-packages/turbogears/controllers.py", line 207, in validate
return errorhandling.run_with_errors(errors, func, args, kw)
File "/usr/lib/python2.6/site-packages/turbogears/errorhandling.py", line 118, in run_with_errors
return func(self, *args,
kw)
File "<string>", line 3, in save
File "/usr/lib/python2.6/site-packages/turbogears/identity/conditions.py", line 249, in require
return fn(self,
args, kwargs)
File "/usr/lib/python2.6/site-packages/bodhi/controllers.py", line 1109, in save
tg_url(update.get_url())))
File "/usr/lib/python2.6/site-packages/bodhi/model.py", line 1451, in add_comment
bz = Bugzilla.get_bz()
File "/usr/lib/python2.6/site-packages/bodhi/model.py", line 1401, in get_bz
password=password, cookiefile=cookie)
File "/usr/lib/python2.6/site-packages/bugzilla/init.py", line 78, in init
c.init(self,
kwargs)
File "/usr/lib/python2.6/site-packages/bugzilla/rhbugzilla.py", line 45, in init
Bugzilla4.init(self, kwargs)
File "/usr/lib/python2.6/site-packages/bugzilla/bugzilla4.py", line 27, in init
Bugzilla36.init(self,
kwargs)
File "/usr/lib/python2.6/site-packages/bugzilla/bugzilla3.py", line 22, in init
bugzilla.base.BugzillaBase.init(self,**kwargs)
File "/usr/lib/python2.6/site-packages/bugzilla/base.py", line 117, in init
self.cookiefile = cookiefile
File "/usr/lib/python2.6/site-packages/bugzilla/base.py", line 185, in _setcookiefile
cj = self._loadcookies(cj)
File "/usr/lib/python2.6/site-packages/bugzilla/base.py", line 158, in _loadcookies
cj.load(self._cookiefile)
File "/usr/lib/python2.6/cookielib.py", line 1763, in load
self._really_load(f, filename, ignore_discard, ignore_expires)
File "/usr/lib/python2.6/_MozillaCookieJar.py", line 55, in _really_load
filename)
LoadError: '/var/tmp/bodhi-bz.cookie' does not look like a Netscape format cookies file
}}}

For some reason there were a couple of empty bz cookie files on our app servers. I just wiped them all out, so could you please try again and see if you can reproduce the issue? Thanks.

I can't reproduce.
Thanks for your action.

I made bodhi handle cookielib.LoadErrors' from python-bugzilla, and wipe out the cookie jar if necessary. So, hopefully we won't see this issue again.

Replying to [comment:5 lmacken]:

I made bodhi handle cookielib.LoadErrors' from python-bugzilla, and wipe out the cookie jar if necessary. So, hopefully we won't see this issue again.

https://fedorahosted.org/bodhi/changeset/386ec147185b7bf6a362f9dd367d7cbe1c70f964

Log in to comment on this ticket.

Metadata