On Fri, Feb 13, 2009 at 1:16 AM, Sandeep <syadd...@gmail.com> wrote:

>
> I just installed Python 2.6.1 and Django 1.0.2 on Windows.
>
> I am new to Python and Django and am following the tutorial for
> Django.
>
> Per tutorial, I am setting the 'DATABASE_ENGINE' to sqlite3 in
> settings.py file. However, I get the following error when I run
> 'python manage.py synchdb':
>
> django.core.exceptions.ImproperlyConfigured: Error loading sqlite3
> module: No module named _sqlite3
>
> Complete error is below. I will greatly appreciate help.
>
> $ python manage.py  syncdb
> [snip]
> 16, in <module>
>    backend = __import__('%s%s.base' % (_import_path,
> settings.DATABASE_ENGINE), {}, {}, [''])
>  File "/usr/lib/python2.5/site-packages/django/db/backends/sqlite3/
> base.py", line 27, in <module>
>    raise ImproperlyConfigured, "Error loading %s module: %s" %
> (module, exc)
> django.core.exceptions.ImproperlyConfigured: Error loading sqlite3
> module: No module named _sqlite3
>

You say Python 2.6.1 on Windows but traceback shows a Python in a python2.5
directory and the command prompt and file paths don't look very Window-y.
Are you using a cygwin bash shell?  If so, the Python 2.6.1 you installed
isn't being used, rather the Python2.5 installed under cygwin is what is
running, and that cygwin install of Python apparently doesn't include
sqlite3, see:

http://www.cygwin.com/ml/cygwin/2007-11/msg00070.html

which is quite old but it doesn't seem they have fixed it.  I just tried
refreshing to the latest Python on one of the boxes where I have cygwin and
I still can't import sqlite3.  The person who had sqlite3 available under
cygwin in that thread was apparently running the Python that came with
something from Cygwin Ports, something I've never used.

If you want the Python 2.6 you installed I think you need to use a Windows
command prompt, not a cygwin bash shell.  If you want to run under cygwin on
Windows, you'll need to figure out how to get sqlite3 support there.

Karen

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to