Merge lp:~adeuring/launchpad/bug-446600 into lp:launchpad

Proposed by Abel Deuring
Status: Merged
Merged at revision: not available
Proposed branch: lp:~adeuring/launchpad/bug-446600
Merge into: lp:launchpad
Diff against target: 25 lines
2 files modified
lib/canonical/launchpad/browser/hwdb.py (+1/-1)
lib/canonical/launchpad/pagetests/hwdb/01-submit-data.txt (+2/-0)
To merge this branch: bzr merge lp:~adeuring/launchpad/bug-446600
Reviewer Review Type Date Requested Status
Paul Hummer (community) Approve
Review via email: mp+13430@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Abel Deuring (adeuring) wrote :

This branch fixes bug 446600: "HWSubmissionMissingFields exceptions should be updated to be informational only"

The fix is quite simple: Diogo added in r9660 a method handling() to our ErrorReportingUtility, which allow to label logged OOPSes as being informational. So I changed the call error_utility.raising() to error_utlitiy.handling()

Test: ./bin/test -f canonical pagetests.hwdb

Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/canonical/launchpad/browser/hwdb.py
  lib/canonical/launchpad/pagetests/hwdb/01-submit-data.txt

Revision history for this message
Paul Hummer (rockstar) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/canonical/launchpad/browser/hwdb.py'
2--- lib/canonical/launchpad/browser/hwdb.py 2009-09-18 20:25:59 +0000
3+++ lib/canonical/launchpad/browser/hwdb.py 2009-10-15 16:40:31 +0000
4@@ -57,7 +57,7 @@
5 info = (HWSubmissionMissingFields,
6 'Missing form fields: %s' % missing_fields, None)
7 errorUtility = getUtility(IErrorReportingUtility)
8- errorUtility.raising(info, self.request)
9+ errorUtility.handling(info, self.request)
10 self.addCustomHeader(
11 'Error: Required fields not contained in POST data: '
12 + missing_fields)
13
14=== modified file 'lib/canonical/launchpad/pagetests/hwdb/01-submit-data.txt'
15--- lib/canonical/launchpad/pagetests/hwdb/01-submit-data.txt 2009-07-23 19:42:59 +0000
16+++ lib/canonical/launchpad/pagetests/hwdb/01-submit-data.txt 2009-10-15 16:40:31 +0000
17@@ -255,6 +255,8 @@
18 Date:...
19 Page-Id: HWDBApplication:+submit
20 ...
21+ Informational: True
22+ ...
23 Traceback (most recent call last):
24 HWSubmissionMissingFields: Missing form fields: distribution,
25 submission_data