Bug 963493

Summary: logpicker's 'report to bugzilla' function is broken
Product: [Fedora] Fedora Reporter: Adam Williamson <awilliam>
Component: anacondaAssignee: Anaconda Maintenance Team <anaconda-maint-list>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 19CC: anaconda-maint-list, dshea, g.kaviyarasu, jonathan, mkolman, sbueno, vanmeeuwen+fedora
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-10-16 21:09:57 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Adam Williamson 2013-05-15 22:40:06 UTC
So, anaconda has this thing called logpicker. Who knew, right?!

It's utils/logpicker (and all the stuff in utils/log_picker/) in the anaconda tree. It appears to have been committed in 2010 and mostly left alone since then.

Admittedly there's a lot of overlap with anaconda's GUI reporting of crashes via libreport. It would be kinda handy to use it to append logs to bugs in certain cases, though - when your bug is a dupe but the devs still want to see the logs, or when your bug is not actually a crash so libreport doesn't pick it up.

However, its Bugzilla reporting functionality is broken ATM. It looks like it's built on libreport, but libreport has changed a lot since it was written, and it just doesn't work any more.

log_picker/sending/__init__.py tries out each of the report functions, and if it doesn't work, basically suppresses it:

try:
    from log_picker.sending.bugzillasender import RedHatBugzilla
except (ImportError):
    NOT_AVAILABLE.append(RHBZ)

That appears to be what happens to the RHBZ function in current anaconda; if you run just 'logpicker' it is not shown in the help output, and if you try 'logpicker --bugzilla' or 'logpicker -b' you get 'no such option'.

If I try and run the test manually in a python env to see what the problem is I get roughly this:

python

import sys
import getpass
import log_picker

from log_picker.sending.bugzillasender import RedHatBugzilla
Traceback...
File "/usr/lib64/python2.7/site-packages/log_picker/sending/bugzillasender.py", line 4, in <module>
    from report.plugins.bugzilla import filer
ImportError: No module named plugins.bugzilla

Indeed, if you look in /usr/lib64/python2.7/site-packages/report , the thing it's trying to import just doesn't appear to exist any more. I don't know libreport well enough to know what it should be doing instead, but it seems clear it ought to be doing...something else.

I don't know if we want to fix this or just declare it dead and maybe enhance the libreport stuff in anaconda proper a bit, I'll leave that up to you folks.

Comment 1 Chris Lumens 2013-10-16 21:09:57 UTC
logpicker has been removed.