Comment 8 for bug 1084979

Revision history for this message
Brian Murray (brian-murray) wrote :

Some apport package hooks, like totem's, will need to be modified so that they still collect data even if ui is None.

def add_info(report, ui):

    response = ui.choice("How would you describe the issue?", ["The totem interface is not working correctly", "No sound is being played", "Some audio files or videos are not being played correctly"], False)

    if response == None: # user cancelled
        raise StopIteration
    .....
    report["LogAlsaMixer"] = apport.hookutils.command_output(["/usr/bin/amixer"])

Because ui is None, then response crashes and the addition of AlsaMixer never happens. However, this can be fixed by either checking for ui or reorganizing the order of operations.