ubuntu general hook should check to see if package install failure has already happened
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
apport (Ubuntu) |
Fix Released
|
High
|
Brian Murray | ||
Precise |
Fix Released
|
High
|
Brian Murray |
Bug Description
[Impact]
Apport notifies you and asks you to file a bug for every package installation failure. If you try and install a broken package 20 times you can be lead to report that bug 20 times. This is wasteful and clutters bug lists.
[Test Case]
1) modify your /etc/default/grub configuration file so that is incorrect for example change the following:
GRUB_CMDLINE_
and remove the trailing quote.
2) sudo apt-get install --reninstall memtest86+
3) This should fail and you will receive an apport dialog indicating that there was a system problem and that memtest86+ failed to install.
4) Remove any memtest86+ files from /var/crash/
5) sudo apt-get install --reinstall memtest86+
6) With the version of apport from precise-proposed as you proceed through the bug filing screens (for the 2nd time) you will be presented with an Unreportable Reason message indicating that you have already encountered this package installation failure.
[Regression potential]
It is possible that other types of apport-package bug reports will be blocked. But as this has been in quantal since July and we are still regularly receiving apport-package bugs it doesn't look like that is the case.
In bug 991282, and its duplicates, we can see a bug reporter (its the same person) running into the same package installation failure at least 48 times. The duplicates here are misleading in that you may thing this bug is really grave until you discover that all the duplicates are from the same reporter. Additionally, the duplicates don't provide any useful information and are wasetful.
We can see that bug 991282 has a DuplicateSignature in it and this is how the apport retracer was able to mark duplicates of it. The DuplicateSignature is created in the general ubuntu hook, ubuntu.py, and I think when this is being created the rest of the DpkgTerminalLog should be scanned for earlier occurences of this error. In the event that we discover the same error we should assume that it has already been reported and not report another bug about it.
Changed in apport (Ubuntu): | |
status: | New → Triaged |
importance: | Undecided → High |
assignee: | nobody → Brian Murray (brian-murray) |
Changed in apport (Ubuntu): | |
status: | Triaged → In Progress |
tags: | added: patch |
Changed in apport (Ubuntu Precise): | |
status: | New → Triaged |
importance: | Undecided → High |
description: | updated |
description: | updated |
Changed in apport (Ubuntu Precise): | |
status: | Triaged → In Progress |
assignee: | nobody → Brian Murray (brian-murray) |
An easy way to test this is to modify your /etc/default/grub configuration file so that is syntactically incorrect for example change the following:
GRUB_CMDLINE_ LINUX_DEFAULT= "quiet splash"
and remove the trailing quote. Then if you try to execute:
sudo apt-get install --reninstall memtest86+
you'll have a package installation failure. If you do this two times you'll be prompted to report two package installation failures - which as previously discussed isn't really useful.
With the attached patch we create a copy of the DpkgTerminalLog without the most recent failure (created by trim_dpkg_log) and then check to see if the duplicate signature is found in the original version of the DpkgTerminalLog. If it is we prevent bug reporting.
This should be SRU'ed to Precise at least.