I am trying to use the django-user-accounts package from pinax. I am completely new to django, and I get stuck at some point, I've been struggling for hours but I still cannot display the account/signup page.
So, I have the following line in my urls.py:
url(r"^account/", include("account.urls")),
Then, I went to check in the urls.py of the account package, and it countains this line.
url(r"^signup/$", SignupView.as_view(), name="account_signup"),
So, when I give the address: 127.0.0.1:8000/account/signup/
in my browser, I think that django should give back the SignupView. But I don't really know what the "as_view()" function does. Usually the second argument of url() should be a function that returns a HTMLResponse. So I went to see in the views.py of the account package: The class SignupView has an attribute
template_name = "account/signup.html"
I would expect the HTMLResponse returned by SignupView.as_view() to be using this template but it doesnt. Instead, I got this error:
TypeError at /
'str' object is not callable
Request Method: GET Request URL: http://127.0.0.1:8000/ Django Version: 1.6.1 Exception Type: TypeError Exception Value:
'str' object is not callable
Exception Location: /usr/lib/python2.7/dist-packages/django/core/handlers/base.py in get_response, line 112 Python Executable: /usr/bin/python Python Version: 2.7.6
Note that this is just the default behaviour of django-user-accounts, I have not modified anything. So I guess that I am missing a dependency or something, but I cannot interprete the error message. By the way, the returned error is exaclty the same as when I give this address in the browser 127.0.0.1:8000/
. Here I expect to receive an error because I have no home page yet, but still, why does the SignupView try to get the html of the root page ???
I am stuck here and I have no idea how I can try to debug this. Any hints would be more than welcome.