Yup, it works using adapter as above and pysqlite-2.5.6. So I should
be fine (until I run into some other reason why py2.3 isn't going to
work for me).

On Jan 20, 10:42 pm, gs_toronto <[email protected]> wrote:
> Thanks, I'll take a look at those. It also looks I was wrong about
> 'pysqlite2' not being a replacement for 'sqlite3' in Py2.5 - it looks
> like they are the same but pysqlite2 is arranged a bit differently, so
> the same import doesn't work; but it seems an adapter can be made so
> that 'import sqlite3' will work. So that could be the easiest.
>
> For the record, the adapter is this file 'sqlite3.py' in site-
> packages:
>
> ----
> from pysqlite2 import dbapi2
> from pysqlite2.dbapi2 import *
> -----
>
> (haven't tried this against django yet. Comparing dbapi2.py against
> the one in py2.5 I also see what looks like a bugfix related to
> microseconds in datetime conversions).
>
> On Jan 20, 8:41 pm, Chris Lee-Messer <[email protected]>
> wrote:
>
> > Yes, it is possible to serve django via cgi
>
> > seehttp://code.djangoproject.com/wiki/ServerArrangements
>
> > However, I would think that you would be better off one of several
> > alternatives that use a second server to run django persistently.
>
> > As one example,  If you can use mod_rewrite on apache, you could proxy
> > to cherrypy's wsgi server.  
> > Seehttp://lincolnloop.com/blog/2008/mar/25/serving-django-cherrypy/
>
> > for an example and code for django_cpserver.
>
> > -C
>
> > On Jan 20, 1:28 pm, gs_toronto <[email protected]> wrote:
>
> > > I have this apache installation which has mod_python, but that's bound
> > > to an existing python2.3 installation (which is in use for other web
> > > app, that uses compiled python extensions which won't work with
> > > py2.5). python2.3 doesn't have sqlite3 module (and 'pysqlite2' add-on
> > > isn't the same).
>
> > > So, I can't use mod_python, and the apache server has been set up
> > > without mod_wsgi or mod_fastsgi.
>
> > > I can create executable files with '#!/usr/local/bin/python' as the
> > > first line, and describe these as CGI scripts to apache. However, I
> > > can find nothing in the django docs to describe how django can be run
> > > this way. Isn't it possible to set up django apps using 'plain CGI'?
> > > It's ok if it's not that efficient. Much better than 'impossible'.
>
> > > Failing that, it seems to me it should be possible to add the sqlite3
> > > library to python2.3, has anyone been able to do that?
-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.


Reply via email to