Thanks. It is still not working but probably for another reason (maybe I have put the admin.py in wrong directory or something).
Your tip of deleting all the pyc files now results in "Discovered!" being printed so I think autodiscover is actually being run now. Its strange but I thought modifying the urls.py source would cause a new pyc file to be created. I wonder why does that not happen? Where does the new autodiscover actually look for relevant admin.py files? On Jan 6, 2:31 pm, "Valts Mazurs" <vald...@gmail.com> wrote: > 1. Check your settings.py if it uses the correct urls.py file. Actually at > first check if the correct settings.py is being used > 2. Remove .pyc and pyo files from your project's directory to be sure that > python interpreter really takes into account changes in source files. > > Regards, > -- > Valts > > On Tue, Jan 6, 2009 at 15:36, bongo <j...@jdiligence.com> wrote: > > > I am in the process of upgrading an old django 0.96 application to > > 1.0.2 final. > > > I am having real trouble getting the admin app to run with my models > > included with the new method. After some trial an error it seems that > > autodiscover is never being called at all in my urls.py. However, the > > url mappings are working. Any one got an idea as to why django might > > not be running autodiscover? > > > from django.contrib import admin > > > admin.autodiscover() > > print "Discovered!" > > > urlpatterns = patterns('', > > (r'^admin/(.*)', admin.site.root), > > .... > > > Thanks > > John --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---