Merge lp:~wxl/ubuntu/hirsute/apport/ubuntu into lp:~ubuntu-core-dev/ubuntu/hirsute/apport/ubuntu

Proposed by ԜаӀtеr Ⅼарсһуnѕkі
Status: Merged
Merged at revision: 2840
Proposed branch: lp:~wxl/ubuntu/hirsute/apport/ubuntu
Merge into: lp:~ubuntu-core-dev/ubuntu/hirsute/apport/ubuntu
Diff against target: 12 lines (+1/-1)
1 file modified
apport/hookutils.py (+1/-1)
To merge this branch: bzr merge lp:~wxl/ubuntu/hirsute/apport/ubuntu
Reviewer Review Type Date Requested Status
Brian Murray Needs Information
Review via email: mp+396949@code.launchpad.net

Commit message

Change default for CasperMD5CheckResult to "unknown."

Description of the change

The reported result of the casper MD5 check is set to "skip" before it is then set to whatever value is found in the results file. This works fine except for older installs before the file check was in place and before the results file was created. That means that new bug reports on recent release versions that were upgraded from older ones will show "skip" suggesting that they skipped the MD5 check, when the reality is actually that we simply don't know what happened.

To post a comment you must log in.
Revision history for this message
Brian Murray (brian-murray) wrote :

I don't recall if a 'result' of 'skip' is actually written to the md5check file. Do you happen to know the answer?

review: Needs Information
Revision history for this message
ԜаӀtеr Ⅼарсһуnѕkі (wxl) wrote :

Yep. Just opened up a Groovy VM and booted with `fsck.mode=skip` and /run/casper-md5check.json had the following contents:

    {
      "result": "skip"
    }

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

Looking at Dimitri's notes again (https://bugs.launchpad.net/ubuntu/+source/apport/+bug/1870408) the absence of the file can also mean that it was skipped. So that's why I went with 'skip' as the default but I can see how this is confusing and 'unknown' is more accurate. Thanks for the fix!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'apport/hookutils.py'
2--- apport/hookutils.py 2020-09-21 17:18:15 +0000
3+++ apport/hookutils.py 2021-01-26 19:26:46 +0000
4@@ -939,7 +939,7 @@
5
6 def attach_casper_md5check(report, location):
7 '''attach the results of the casper md5check of install media'''
8- result = 'skip'
9+ result = 'unknown'
10 mismatches = []
11 if os.path.exists(location):
12 with open(location) as json_file:

Subscribers

People subscribed via source and target branches