mercredi 22 avril 2015

django on jython using django-jython

I would appreciate it if you read my poor English

I use :

windows

Jython 2.7rc2

jdk-8u45

django 1.8

django-jython 1.7.0b2

I try jython startproject mysite, and succeed

then I try jython manage.py runserver 8080 and fail

Detail:

In settings.py :

     in DATABASES :
                     'ENGINE': 'doj.db.backends.sqlite3'
     in INSTALLED_APPS:
                      I add  'doj',

The same with http://ift.tt/1HtGQbS

The results:

raise ImproperlyConfigured(error_msg)django.core.exceptions.ImproperlyConfigured:'doj.db.backends.sqlite' isn't an a vailable database backend. Try using 'django.db.backends.XXX', where XXX is one of: u'base', u'mysql', u'oracle', u'postgresql_psycopg2', u'sqlite3' Error was: cannot import name BaseDatabaseWrapper

so I try django.db.backends.sqlite instead of doj.db.backends.sqlite in settings.py at DATABASES

and unluckily:

raise ImproperlyConfigured("Error loading either pysqlite2
or sqlite3 modules (tried in that order): %s" % exc) django.core.exceptions.ImproperlyConfigured: Error loading either pysqlite2 or sqlite3 modules (tried in that order): No module named sqlite3

I have searched and try all day already but still can not solve.

thanks for your help!!!

Aucun commentaire:

Enregistrer un commentaire