title: Error when wrapping the view of a 3rd-party Django app? (Facebook, django-socialregistration, django-profiles)
body: <p>I'm using <strong>django-socialregistration</strong> to manage my site's connection with Facebook.  </p>
  
  <p>When a user clicks the "Connect with Facebook" button, I am able to automatically create a new Django user and log them in. However, I also need to create a UserProfile (my AUTH_PROFILE_MODULE) record for them which contains their Facebook profile information (email, name, location).</p>
  
  <p>I believe I need to override socialregistration's "setup" view so I can do what I need to do with UserProfile. I've added the following to my project's urls.py file:  </p>
  
  <blockquote>
    <p>url( r'^social/setup/$', 'myapp.views.socialreg.pre_setup', name='socialregistration_setup'),  </p>
  </blockquote>
  
  <p>My custom view is here "/myapp/views/socialreg.py" and looks like:  </p>
  
  <pre><code>from socialregistration.forms import UserForm
  
  def pre_setup(request, template='socialregistration/setup.html', 
                form_class=UserForm, extra_context=dict()):
      # will add UserProfile storage here...
      return socialregistration.views.setup(request, template, form_class, extra_context)
  </code></pre>
  
  <p>The socialregistration view signature I'm overriding looks like this:  </p>
  
  <pre><code>def setup(request, template='socialregistration/setup.html',
            form_class=UserForm, extra_context=dict()):
      ...
  </code></pre>
  
  <p>I'm getting the error <strong>"ViewDoesNotExist at /social/setup/: Could not import myapp.views.socialreg. Error was: No module named socialregistration.views"</strong> when I try the solution above.</p>
  
  <p>The socialregistration app is working fine when I don't try to override the view, so it is likely installed correctly in site-packages. Anyone know what I'm doing wrong?</p>