Add the recaptcha module
Review Request #7937 — Created Feb. 1, 2016 and submitted
The
djblets.recaptcha
module provides a form mixin that supports
reCAPTCHA API version 2.reCAPTCHA is an implementation of CAPTCHA (Completely Automated
Public Turing Test to tell Computers and Humans Apart) by Google.
It is used in web forms to prevent them from being filled out and
submitted by automated bots.
- Used this with Splat.
- Ran unit tests.
- Built and viewed the docs.
Description | From | Last Updated |
---|---|---|
Col: 1 W391 blank line at end of file |
reviewbot | |
Can you extend this to say how it's used? Might also be nice to include a reference to the guide. |
chipx86 | |
"reCAPTCHA" |
chipx86 | |
Maybe we should say to contact an administrator. |
chipx86 | |
Let's check for a KeyError on access, in case we somehow get something we don't expect. |
chipx86 | |
Can we call this recaptcha_form_field? |
chipx86 | |
In case we decide to backport any of this (wouldn't be bad to have in a 2.5), we should use … |
chipx86 | |
This file is intended only for built-in Django settings. Maybe we want a Djblets equivalent, but I think we should … |
chipx86 | |
Space before <. |
chipx86 | |
It'd be cool to have a little example showing a form's HTML and mixing in. Though it's easy to do, … |
chipx86 | |
Trailing blank line. |
chipx86 | |
'settings' imported but unused |
reviewbot | |
'format_html' imported but unused |
reviewbot | |
With logging.exception you don't need to format the exception into the log string. This should also be "reCAPTCHA", not "ReCaptcha" |
david | |
With logging.exception you don't need to format the exception into the log string. |
david | |
Too many blank lines here. |
david | |
IIRC the description should go on the next line. |
david |
-
Tool: Pyflakes Processed Files: djblets/siteconfig/django_settings.py djblets/recaptcha/mixins.py djblets/recaptcha/__init__.py djblets/recaptcha/apps.py Ignored Files: docs/djblets/coderef/index.rst Tool: PEP8 Style Checker Processed Files: djblets/siteconfig/django_settings.py djblets/recaptcha/mixins.py djblets/recaptcha/__init__.py djblets/recaptcha/apps.py Ignored Files: docs/djblets/coderef/index.rst
-
Tool: Pyflakes Processed Files: djblets/siteconfig/django_settings.py djblets/recaptcha/mixins.py djblets/recaptcha/__init__.py djblets/recaptcha/apps.py Ignored Files: docs/djblets/coderef/index.rst Tool: PEP8 Style Checker Processed Files: djblets/siteconfig/django_settings.py djblets/recaptcha/mixins.py djblets/recaptcha/__init__.py djblets/recaptcha/apps.py Ignored Files: docs/djblets/coderef/index.rst
-
Tool: PEP8 Style Checker Processed Files: djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/siteconfig/django_settings.py djblets/recaptcha/mixins.py djblets/recaptcha/__init__.py djblets/recaptcha/apps.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst Tool: Pyflakes Processed Files: djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/siteconfig/django_settings.py djblets/recaptcha/mixins.py djblets/recaptcha/__init__.py djblets/recaptcha/apps.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst
-
Awesome :)
Some thoughts, mostly doc/error-related.
-
-
-
-
-
-
In case we decide to backport any of this (wouldn't be bad to have in a 2.5), we should use
{0}
instead of{}
, as the latter breaks on Python 2.6. -
This file is intended only for built-in Django settings. Maybe we want a Djblets equivalent, but I think we should do what
djblets.log
does, where there's asiteconfig.py
indjblets.recaptcha
that provides the settings map and lets the caller use it. -
-
It'd be cool to have a little example showing a form's HTML and mixing in. Though it's easy to do, having it as reference will be useful.
Also, an example with using this in a
SiteConfiguration
would be good. -
-
Oh also, can you add more to the description for the commit? There's not much info on what this is for, especially if you don't know reCAPTCHA.
-
Tool: Pyflakes Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/siteconfig/django_settings.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst Tool: PEP8 Style Checker Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/siteconfig/django_settings.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst
-
-
- Description:
-
The
djblets.recaptcha
module provides a form mixin that supportsreCAPTCHA API version 2. + + reCAPTCHA is an implementation of CAPTCHA (Completely Automated
+ Public Turing Test to tell Computers and Humans Apart) by Google. + It is used in web forms to prevent them from being filled out and + submitted by automated bots.
-
Tool: Pyflakes Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/siteconfig/django_settings.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst Tool: PEP8 Style Checker Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/siteconfig/django_settings.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst
-
Tool: Pyflakes Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/siteconfig/django_settings.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst Tool: PEP8 Style Checker Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/siteconfig/django_settings.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst
-
Tool: Pyflakes Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst Tool: PEP8 Style Checker Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst
-
Tool: PEP8 Style Checker Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst Tool: Pyflakes Processed Files: djblets/recaptcha/siteconfig.py djblets/recaptcha/apps.py djblets/recaptcha/__init__.py djblets/recaptcha/mixins.py djblets/recaptcha/templatetags/djblets_recaptcha.py djblets/recaptcha/widgets.py Ignored Files: docs/djblets/guides/recaptcha/index.rst docs/djblets/guides/recaptcha/using-recaptcha.rst docs/djblets/guides/index.rst djblets/recaptcha/templatetags/__init__.py docs/djblets/coderef/index.rst