I was walking through the Django getting started tutorial, and I am getting an error running this code:
I created a database and updated the settings.py file, but I keep getting an error saying my database engine was not set (I have Xed out my name, user, and password; but it's correct in the file):
This is the error that I am getting:
Any feedback would be much appreciated. Thanks. asked 20 Jan '11, 14:03 tdavis |
The settings.py file was not UNIX formatted. You must have used an editor in another OS to edit the file. I fixed it by running,
answered 20 Jan '11, 17:40 johns |
That's really weird, I was using TextMate on a mac to edit that file. But you are right, it did end up working, thanks. Although I was not prompted to create a super user. Is there a default one? answered 21 Jan '11, 07:57 tdavis No, there is no default superuser. If you started off with an empty database, you should be prompted for a superuser during "syncdb" (unless you ran it with --noinput option).
(21 Jan '11, 08:04)
tie
I did start with an empty database. I just ran python2.6 manage.py syncdb.
(21 Jan '11, 08:06)
tdavis
Did you enable the admin application at all? Did syncdb create any of the admin tables?
(21 Jan '11, 08:12)
tie
I followed the steps in the getting started tutorial and thought I enabled the admin app. INSTALLED_APPS = ( 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.admin', # Uncomment the next line to enable admin documentation: # 'django.contrib.admindocs', ) I don't see any admin tables in there though.
(21 Jan '11, 08:20)
tdavis
Most likely there is something wrong with your Django configuration. I'd suggest opening up a support ticket about it.
(21 Jan '11, 09:03)
tie
|