Merge lp://staging/~jml/pkgme/want-null into lp://staging/pkgme

Proposed by Jonathan Lange
Status: Merged
Approved by: James Westby
Approved revision: 135
Merged at revision: 132
Proposed branch: lp://staging/~jml/pkgme/want-null
Merge into: lp://staging/pkgme
Diff against target: 100 lines (+37/-9)
2 files modified
pkgme/backend.py (+5/-7)
pkgme/tests/test_backend.py (+32/-2)
To merge this branch: bzr merge lp://staging/~jml/pkgme/want-null
Reviewer Review Type Date Requested Status
James Westby Approve
Review via email: mp+121187@code.staging.launchpad.net

Commit message

Be crystal clear when the want script returns null

Description of the change

The 'want' script can return JSON. 'null' is acceptable JSON which Python
turns into 'None'. Our WantError exception class was using 'None' to mean
"there is no data" and was thus not printing the output of the 'want' script.

This patch fixes that by making the 'data' parameter mandatory, and adds
some tests.

To post a comment you must log in.
Revision history for this message
James Westby (james-w) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches