Merge lp:~mvo/piston-mini-client/validation-tweaks into lp:piston-mini-client

Proposed by Michael Vogt
Status: Merged
Merged at revision: 66
Proposed branch: lp:~mvo/piston-mini-client/validation-tweaks
Merge into: lp:piston-mini-client
Diff against target: 13 lines (+2/-1)
1 file modified
piston_mini_client/validators.py (+2/-1)
To merge this branch: bzr merge lp:~mvo/piston-mini-client/validation-tweaks
Reviewer Review Type Date Requested Status
Anthony Lenton Approve
Review via email: mp+135624@code.launchpad.net

Description of the change

trivial branch as I was stumbling over a str vs unicode issue

To post a comment you must log in.
Revision history for this message
Anthony Lenton (elachuni) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'piston_mini_client/validators.py'
2--- piston_mini_client/validators.py 2012-07-30 17:09:26 +0000
3+++ piston_mini_client/validators.py 2012-11-22 10:25:23 +0000
4@@ -63,7 +63,8 @@
5 if varname in kwargs:
6 if not isinstance(kwargs[varname], cls):
7 raise ValidationException(
8- "Argument '%s' must be a %s" % (varname, cls))
9+ "Argument '%s' must be a %s instead of %s" % (
10+ varname, cls, type(kwargs[varname])))
11 elif required:
12 raise ValidationException(
13 "Required named argument '%s' missing" % varname)

Subscribers

People subscribed via source and target branches