Merge lp://staging/~ev/daisy/refactor-submission into lp://staging/daisy
Status: | Merged |
---|---|
Approved by: | Brian Murray |
Approved revision: | 309 |
Merged at revision: | 312 |
Proposed branch: | lp://staging/~ev/daisy/refactor-submission |
Merge into: | lp://staging/daisy |
Diff against target: |
379 lines (+186/-86) 5 files modified
daisy/retracer.py (+1/-2) daisy/schema.py (+6/-1) daisy/submit.py (+99/-73) daisy/utils.py (+13/-10) test/test_submit.py (+67/-0) |
To merge this branch: | bzr merge lp://staging/~ev/daisy/refactor-submission |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Daisy Pluckers | Pending | ||
Review via email: mp+158566@code.staging.launchpad.net |
Description of the change
This branch refactors the crash submission process. This in turn fixes the submission of kernel OOPS reports since we now first rely on apport to generate a crash signature from the data we have, then fall through to trying to find a matching signature in the database for binary crashes. The old behaviour was to attempt to isolate each type of problem we supported, and it was prone to breakage (as was the case with kernel OOPS).
The branch also adds a new Column Family, CouldNotBucket. This CF will contain the OOPS IDs (as actual uuid()s) for the day period that were not bucketed because no crash signature could be produced and they did not appear to be a binary crash.
I've also moved the creation and modification of the crash signature into the utils module, ensuring that the signature always gets truncated to the same length and always encoded as a utf-8 string.
This looks good aside of a couple of minor nits which follow in line.
On Fri, Apr 12, 2013 at 11:28:29AM -0000, Evan Dandrea wrote: /code.launchpad .net/~ev/ daisy/refactor- submission/ +merge/ 158566 /code.launchpad .net/~ev/ daisy/refactor- submission/ +merge/ 158566
> Evan Dandrea has proposed merging lp:~ev/daisy/refactor-submission into lp:daisy.
>
> Requested reviews:
> Daisy Pluckers (daisy-pluckers)
>
> For more details, see:
> https:/
>
> This branch refactors the crash submission process. This in turn fixes the submission of kernel OOPS reports since we now first rely on apport to generate a crash signature from the data we have, then fall through to trying to find a matching signature in the database for binary crashes. The old behaviour was to attempt to isolate each type of problem we supported, and it was prone to breakage (as was the case with kernel OOPS).
>
> The branch also adds a new Column Family, CouldNotBucket. This CF will contain the OOPS IDs (as actual uuid()s) for the day period that were not bucketed because no crash signature could be produced and they did not appear to be a binary crash.
>
> I've also moved the creation and modification of the crash signature into the utils module, ensuring that the signature always gets truncated to the same length and always encoded as a utf-8 string.
> --
> https:/
> You are subscribed to branch lp:daisy.
> === modified file 'daisy/retracer.py' 'StacktraceAddr essSignature' ] crash_signature () crash_signature (report) .encode( 'utf-8' ) type=ASCII_ TYPE) atures' not in cfs: 1779(mgr. create_ column_ family, keyspace, 'BugToCrashSign atures' , class=INTEGER_ TYPE, class=INT_ TYPE, type=UTF8_ TYPE) 1779(mgr. create_ column_ family, keyspace, 'CouldNotBucket', type=TIME_ UUID_TYPE) release_ pkg_counter( counters_ fam, release, src_package, date): fam.insert( '%s:%s' % (release, src_package), ...
> --- daisy/retracer.py 2013-04-10 13:32:23 +0000
> +++ daisy/retracer.py 2013-04-12 11:27:29 +0000
> @@ -603,10 +603,9 @@
> report.load(fp)
> stacktrace_addr_sig = report[
>
> - crash_signature = report.
> + crash_signature = utils.generate_
> if crash_signature:
> has_signature = True
> - crash_signature = crash_signature
>
> if has_signature:
> try:
>
> === modified file 'daisy/schema.py'
> --- daisy/schema.py 2013-03-28 00:44:05 +0000
> +++ daisy/schema.py 2013-04-12 11:27:29 +0000
> @@ -21,6 +21,8 @@
> UTF8_TYPE,
> LONG_TYPE,
> ASCII_TYPE,
> + INT_TYPE,
> + TIME_UUID_TYPE,
> )
>
> from daisy import config
> @@ -69,8 +71,11 @@
> comparator_
> if 'BugToCrashSign
> workaround_
> - key_validation_
> + key_validation_
> comparator_
> + if 'CouldNotBucket' not in cfs:
> + workaround_
> + comparator_
> finally:
> mgr.close()
>
>
> === modified file 'daisy/submit.py'
> --- daisy/submit.py 2013-04-06 22:25:02 +0000
> +++ daisy/submit.py 2013-04-12 11:27:29 +0000
> @@ -40,14 +40,27 @@
> def update_
> counters_