Commit 9e6a63b6 by Ned Batchelder

Fix translation-of-non-string errors

parent 0c8fcf6a
...@@ -496,7 +496,7 @@ def shib_login(request): ...@@ -496,7 +496,7 @@ def shib_login(request):
http://www.incommonfederation.org/attributesummary.html#eduPersonPrincipal http://www.incommonfederation.org/attributesummary.html#eduPersonPrincipal
but the configuration is in the shibboleth software. but the configuration is in the shibboleth software.
""" """
shib_error_msg = _(dedent( shib_error_msg = dedent(_(
""" """
Your university identity server did not return your ID information to us. Your university identity server did not return your ID information to us.
Please try logging in again. (You may need to restart your browser.) Please try logging in again. (You may need to restart your browser.)
......
...@@ -369,6 +369,7 @@ def validate_user_preference_serializer(serializer, preference_key, preference_v ...@@ -369,6 +369,7 @@ def validate_user_preference_serializer(serializer, preference_key, preference_v
PreferenceValidationError: the supplied key and/or value for a user preference are invalid. PreferenceValidationError: the supplied key and/or value for a user preference are invalid.
""" """
if preference_value is None or unicode(preference_value).strip() == '': if preference_value is None or unicode(preference_value).strip() == '':
# pylint: disable=translation-of-non-string
format_string = ugettext_noop(u"Preference '{preference_key}' cannot be set to an empty value.") format_string = ugettext_noop(u"Preference '{preference_key}' cannot be set to an empty value.")
raise PreferenceValidationError({ raise PreferenceValidationError({
preference_key: { preference_key: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment