Re: Django-Registration/Custom Authentication Issue

2013-04-19 Thread Lee Hinde
Thanks. On Fri, Apr 19, 2013 at 4:41 AM, Paul Walsh wrote: > These are the changes you'll have to make to django-registration, if you > are using AUTH_USER_MODEL in django 1.5 and inheriting from AbstractUser: > > > https://bitbucket.org/prjts/django-registration/commits/ba31fc3053bfca7eb7a19d9

Re: Django-Registration/Custom Authentication Issue

2013-04-19 Thread Paul Walsh
These are the changes you'll have to make to django-registration, if you are using AUTH_USER_MODEL in django 1.5 and inheriting from AbstractUser: https://bitbucket.org/prjts/django-registration/commits/ba31fc3053bfca7eb7a19d912882e50e295adc55 On Friday, 19 April 2013 11:52:55 UTC+3, Paul Wals

Re: Django-Registration/Custom Authentication Issue

2013-04-19 Thread Paul Walsh
James Bennet says above that it is compatible, but the latest django-registration code is not compatible with custom user models. RegistrationProfile, for example, still refers directly to User, whereas the new custom user implementation in Django 1.5 require this to be changed in order to work

Re: Django-Registration/Custom Authentication Issue

2013-04-17 Thread Scott Anderson
That's good to know. How stable is it? -scott Via mobile phone On Apr 17, 2013, at 3:52 AM, James Bennett wrote: Current hg tip is actually 1.5-compatible, in the sense that if you want to use your own User model, you just subclass the provided stuff and plug in your model, either importing di

Re: Django-Registration/Custom Authentication Issue

2013-04-17 Thread James Bennett
Current hg tip is actually 1.5-compatible, in the sense that if you want to use your own User model, you just subclass the provided stuff and plug in your model, either importing directly or using the helper function in Django 1.5. django-registration does not do this itself because 1. Using Djan

Re: Django-Registration/Custom Authentication Issue

2013-04-16 Thread Lee Hinde
Thanks Scott; that turned out to be the issue. I found those references and updated them and all is well. On Apr 16, 2013, at 7:05 PM, Scott Anderson wrote: > Django registration is not compatible with custom user models in Django 1.5, > as it directly references django.contrib.auth.models.Use

Re: Django-Registration/Custom Authentication Issue

2013-04-16 Thread Scott Anderson
Django registration is not compatible with custom user models in Django 1.5, as it directly references django.contrib.auth.models.User in several places. If you want to maintain your own copy you can swap those refs for those of your own User model. -scott Via mobile phone On Apr 16, 2013, at 9

Re: Django-Registration/Custom Authentication Issue

2013-04-16 Thread Rainy
On Sunday, April 14, 2013 9:49:32 PM UTC-4, Lee Hinde wrote: > > I'm trying to do a 'simple' registration with just a user email and > password required to create an account. I'm using django-registration with > django 1.5.1 and have created a custom model and the custom model manager. > > I

Django-Registration/Custom Authentication Issue

2013-04-14 Thread Lee Hinde
I'm trying to do a 'simple' registration with just a user email and password required to create an account. I'm using django-registration with django 1.5.1 and have created a custom model and the custom model manager. I can hit all the registration forms just fine and have copied the example from

Re: Authentication issue

2010-02-24 Thread Les Smithson
request.user.is_anonymous() and django.contrib.auth.logout() respectively. On Feb 24, 2:36 pm, CrabbyPete wrote: > I have code that allows an anonymous user to look at some elses page, > but I want to limit what they can do so I have the following code > > def show(request): >      u = request.

Re: Authentication issue

2010-02-24 Thread Daniel Roseman
On Feb 24, 2:36 pm, CrabbyPete wrote: > I have code that allows an anonymous user to look at some elses page, > but I want to limit what they can do so I have the following code > > def show(request): >      u = request.GET['friend'] >      user = User.objects.get(pk=u) >      visit = user.is_auth

Authentication issue

2010-02-24 Thread CrabbyPete
I have code that allows an anonymous user to look at some elses page, but I want to limit what they can do so I have the following code def show(request): u = request.GET['friend'] user = User.objects.get(pk=u) visit = user.is_authenticated() visit should be false, but it keeps com

Re: Authentication Issue: Unregistered username with blank password

2010-02-17 Thread Timothy Kinney
Whoops. I figured it out. Even though the user is None, it is failing the form.is_valid() check and so skipping the if statements. So I just need to include an else clause for the form.is_valid() check to catch the blank password situation. Here's hoping this helps someone else. On Wed, Feb 17, 2

Authentication Issue: Unregistered username with blank password

2010-02-17 Thread Timothy Kinney
I am using a basic authentication/login scheme in Django 1.1.1 and Python 2.5.3. It behaves correctly if I login correctly, or if I use use a correct username but wrong password. It also works for an unknown username AND any password. However, if I type in a username that is not in the database wit