- '<a href="%s">Log in</a> or <a href="%s">reset your password</a>.') % (
- reverse('login'), reverse('password_reset'))
+ '<a href="%(login_url)s">Log in</a> or <a href="%(reset_url)s">reset your password</a>.') % {
+ 'login_url': reverse('login'),
+ 'reset_url': reverse('password_reset'),
+ }