Re: [Python-Dev] Building thread-safe sqlite3 with Python 2.6.5rc1

2010-03-09 Thread Darren Govoni
That worked great Oleg! Thank you!

On Tue, 2010-03-09 at 01:52 +0300, Oleg Broytman wrote:

> On Mon, Mar 08, 2010 at 05:28:10PM -0500, Darren Govoni wrote:
> > ProgrammingError: SQLite objects created in a thread can only be used in
> > that same thread.The object was created in thread id -1217128768 and
> > this is thread id -1218753680
> 
>Darren, try to pass check_same_thread=False when creating a connection.
> 
> Oleg.


___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Building thread-safe sqlite3 with Python 2.6.5rc1

2010-03-08 Thread Darren Govoni
Thanks. It says.

sqlite: found /usr/local/include/sqlite3.h
/usr/local/include/sqlite3.h: version 3.6.22

Which is correct. Yet when I run my progam using the newly built python
executable and attempt to use sqlite3
functionality across threads it still says:

ProgrammingError: SQLite objects created in a thread can only be used in
that same thread.The object was created in thread id -1217128768 and
this is thread id -1218753680

I set the -DSQLITE_THREADSAFE=1 flag on sqlite3 when I configured, built
and installed the lib.

Darren

On Mon, 2010-03-08 at 22:52 +0100, "Martin v. Löwis" wrote:

> > thanks for any tips.
> 
> Set sqlite_setup_debug to True in setup.py
> 
> Regards,
> Martin


___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


[Python-Dev] Building thread-safe sqlite3 with Python 2.6.5rc1

2010-03-08 Thread Darren Govoni
Hi,
  I'm trying to get the thread-safe enabled for sqlite3 in my build of
2.6.5rc1, but its not taking and throws the old thread access error.
I am running Ubuntu with other versions of Python, but I successfully
built and installed sqlite 3.6.22, pysqlite 2.6.0.
Do I have to set something explicit when building python 2.6.5 to find
the updated sqlite3?

thanks for any tips.
Darren
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com