From b05272338c8d2fa8393ed5489c2bdebe16eb46a7 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Mon, 24 Jan 2011 22:05:23 -0500 Subject: render token in ValueError instead of passing it as a second arg --- pyramid/authentication.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyramid/authentication.py b/pyramid/authentication.py index 0484687ed..cee339532 100644 --- a/pyramid/authentication.py +++ b/pyramid/authentication.py @@ -483,7 +483,7 @@ class AuthTktCookieHelper(object): for token in tokens: if not (isinstance(token, str) and VALID_TOKEN.match(token)): - raise ValueError("Invalid token %r", token) + raise ValueError("Invalid token %r" % (token,)) ticket = self.auth_tkt.AuthTicket( self.secret, -- cgit v1.2.3