2degrees/django-recaptcha-field — pull request #4 by mathiasertl (2013-12-16 20:12:07+00:00)
Title: Fix KeyError when RecaptchaInvalidChallengeError is handled

When ``is_solution_correct`` raises ``RecaptchaInvalidChallengeError`` in line 92, the exception-handler accesses ``self.error_messages['invalid']``, which is not present, since ``_RecaptchaField.default_error_messages`` doesn't define it.

It is very hard to trigger this exception and I have not myself been able to reproduce it, but I do receive Django tracebacks via email every now and then. This oneliner should fix the issue.