~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/hardwaredb/stories/hwdb/xx-hwdb.txt

  • Committer: Launchpad Patch Queue Manager
  • Date: 2011-08-16 20:38:35 UTC
  • mfrom: (13686.2.17 useoops)
  • Revision ID: launchpad@pqm.canonical.com-20110816203835-4q78rt0xz6zzuyka
[r=gmb][no-qa] More oops extraction. New deps oops-0.0.5
 oops-datedir-repo-0.0.2.

Show diffs side-by-side

added added

removed removed

Lines of Context:
217
217
    POST data: submission_data
218
218
    ...
219
219
 
220
 
Also, an OOPS is reported.
221
 
 
222
 
    >>> from canonical.launchpad.webapp.errorlog import ErrorReportingUtility
223
 
    >>> error_utility = ErrorReportingUtility()
224
 
    >>> error_report = error_utility.getLastOopsReport()
225
 
    >>> error_report.type
226
 
    'HWSubmissionMissingFields'
227
 
    >>> error_report.value
228
 
    'Missing form fields: submission_data'
229
 
    >>> error_report.pageid
230
 
    'HWDBApplication:+submit'
231
 
 
232
 
    >>> del form_data['field.distribution']
233
 
    >>> browser.open('http://launchpad.dev/+hwdb/+submit',
234
 
    ...     data=urlencode(form_data))
235
 
    >>> print browser.headers
236
 
    Status: 200 Ok
237
 
    ...
238
 
    X-Launchpad-Hwdb-Submission: Error: Required fields not contained in
239
 
    POST data: distribution, submission_data
240
 
    ...
241
 
 
242
 
    >>> error_report = error_utility.getLastOopsReport()
243
 
    >>> error_report.type
244
 
    'HWSubmissionMissingFields'
245
 
    >>> error_report.value
246
 
    'Missing form fields: distribution, submission_data'
247
 
    >>> error_report.pageid
248
 
    'HWDBApplication:+submit'
249
 
    >>> error_report.informational
250
 
    'True'
251
 
 
252
220
= Views for raw submission data. =
253
221
 
254
222
The raw submission data is listed by submitter and by system fingerprint.