Search code examples
djangoherokurecaptchapipdjango-registration

Using django-registration with recaptcha on Heroku


I'd like to try Django on Heroku. I'd like user registration with recaptcha.

Heroku recommends using pip. pip installs django-registration 0.7, since that's the latest released package. (0.8 has apparently been in alpha for 4 years?). django-recaptcha requires django-registration 0.8. When I pip install django-recaptcha, it tries to pip install django-registration, gets 0.7, and is sad.

What's the easiest thing to maintain? Should I not use pip for these, download both tarballs and put them in my source tree?

I am surprised that user registration with captchas is not smooth in a framework that's been around as long as Django.


Solution

  • You can edit the requirements.txt file to take a specific version of the django-registration repo ("tip" is a good choice for django-registration at the moment):

    Replace you the line in your requirements file which looks like this:

    django-registration==0.7
    

    with:

    hg+https://bitbucket.org/ubernostrum/django-registration/@tip