Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8541689
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T11:53:15+00:00 2026-06-11T11:53:15+00:00

I have been searching the web, (and StackOverflow), for an answer to what appears

  • 0

I have been searching the web, (and StackOverflow), for an answer to what appears to be a REALLY simple problem. I am using django-userena with a custom form.

Inside my form.py is:

class RegistrationForm(SignupFormOnlyEmail):

    first_name = forms.CharField(label='First Name', max_length=30, required=True, error_messages={'required':'Please Provide Your First Name'})
    last_name = forms.CharField(label='Last Name', max_length=30, required=True)
    email2 = forms.EmailField(widget=forms.TextInput(attrs=dict(attrs_dict, maxlength=75)), label=_("Retype Email"), required=True)
    parent_type = forms.ChoiceField(label="I am a", choices=ACCOUNT_TYPES, widget=forms.RadioSelect)
    child_count = forms.ChoiceField(label="My Kids", choices=KID_CHOICES, widget=forms.Select)
    grade = forms.ChoiceField(label="My Classroom", choices=GRADE_CHOICES, widget=forms.Select)
    tos = forms.BooleanField(label="I accept the Terms of Use.", required=True)

    def __init__(self, *args, **kwargs):

        self.initial = kwargs.pop('initial', None)
        kidCount = self.initial['child_count']
        account_type = self.initial['parent_type']

        super(RegistrationForm, self).__init__(*args, **kwargs)

Inside of my urls.py I put:

url(r'^membership/signup/$', signup_view, name='userena_signup'),

My custom view looks like this:

def signup_view(request):

    form = RegistrationForm(initial={'parent_type':request.session['parent_type'],'child_count':request.session['child_count']})
    response = userena_views.signup(request,  signup_form=form, extra_context={'section':'Membership','pagetitle':'Sign Up'})
    return response

When I post the form and go to the /membership/signup/, I get a “TypeError” of

‘RegistrationForm’ object is not callable

Here is a dump of the stack trace:

Traceback:
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/django/core/handlers/base.py” in get_response
111. response = callback(request, *callback_args, **callback_kwargs)
File “/Users/lawrenceleach/Dropbox/Sites/django/wonderville/membership/views.py” in signup_view
42. response = userena_views.signup(request, signup_form=form, extra_context={‘section’:’Membership’,’pagetitle’:’Sign Up’})
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/userena/decorators.py” in _wrapped_view
28. return view_func(request, *args, **kwargs)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/userena/views.py” in signup
115. form = signup_form()

Exception Type: TypeError at /membership/signup/
Exception Value: ‘RegistrationForm’ object is not callable

Like I said, I’m sure the answer is staring me right in the face and I just can’t see it. Any help would be greatly appreciated.

Thank you in advance!

L.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T11:53:17+00:00Added an answer on June 11, 2026 at 11:53 am

    The solution was to pass the initial form values as a dictionary object to the “extra_context” variable of the form call in the view. If had been using Django’s built-in form tool then what I originally had done above would have worked. I posted the issue to the Userena folks. It appears to be a bug within their system.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been searching the web for an answer to my problem, but so
I have been searching the web for a concrete and simple example of binding
I have been searching the web and all over stackoverflow, but yet couldn't find
I have been searching the web for an answer now for quite a while,
I have been searching in stackoverflow for a question similar to mine because it
I have been searching for an answer and trying out stuff for days now
I have been searching for a few hours and cant seem to find answer
So i have been searching the web for a javascript source for an Hmac-sha1
I've been searching through the web but I have not been able to find
I have been searching the web looking for a definition for declarative and imperative

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.