Re: 'settings' referenced before assignment

2011-07-20 Thread ydjango
Thank you. That was exactly the issue. I renamed the local variable. On Jul 20, 2:04 pm, Ian Clelland wrote: > On Wed, Jul 20, 2011 at 1:14 PM, ydjango wrote: > > Occasionally I see this error in my app, > > > UnboundLocalError: local variable 'settings' refe

Re: 'settings' referenced before assignment

2011-07-20 Thread Ian Clelland
On Wed, Jul 20, 2011 at 1:14 PM, ydjango wrote: > Occasionally I see this error in my app, > > UnboundLocalError: local variable 'settings' referenced before > assignment > > I have in my views .py > > from django.conf import settings > other imports... &

'settings' referenced before assignment

2011-07-20 Thread ydjango
Occasionally I see this error in my app, UnboundLocalError: local variable 'settings' referenced before assignment I have in my views .py from django.conf import settings other imports... def new_view(request): if not request.user.is_authenticated():