From a324c1fc19b6ae49da879f804c8e20b8a6d34db7 Mon Sep 17 00:00:00 2001 From: John Anderson Date: Thu, 17 Oct 2013 20:27:27 -0700 Subject: Use pretty formatting --- jsonschema/exceptions.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/jsonschema/exceptions.py b/jsonschema/exceptions.py index 30419ae..c6e5ad9 100644 --- a/jsonschema/exceptions.py +++ b/jsonschema/exceptions.py @@ -106,12 +106,14 @@ class UnknownType(Exception): pinstance = pprint.pformat(self.instance, width=72) return textwrap.dedent(""" Uknown Type: %s, in schema: - %r + %s On instance: - %s + %s """.rstrip() - ) % (self.type, self.schema, self.instance) + ) % (self.type, + _utils.indent(pschema), + _utils.indent(pinstance)) -- cgit v1.2.1