Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Richard Hipp
On Mon, Sep 8, 2014 at 1:56 PM, Andres Riancho wrote: > On Mon, Sep 8, 2014 at 2:27 PM, Roger Binns wrote: > > > > It sounds like what you could use temporary tables and let SQLite do the > > work for you. > > > Hmmm. How about this. Stop

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Andres Riancho
On Mon, Sep 8, 2014 at 2:37 PM, Roger Binns wrote: > On 08/09/14 03:49, Andres Riancho wrote: >> Off-list some guys contacted me and mentioned APSW [0], another >> wrapper around sqlite for python, and said that it might be worth >> giving it a try. Do you guys believe that

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Andres Riancho
On Mon, Sep 8, 2014 at 2:27 PM, Roger Binns wrote: > On 08/09/14 03:29, Andres Riancho wrote: >> In my project we use the database to store data during the process >> life, and then remove it when the process finishes. > > It sounds like what you could use temporary tables

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Roger Binns
On 08/09/14 03:49, Andres Riancho wrote: > Off-list some guys contacted me and mentioned APSW [0], another > wrapper around sqlite for python, and said that it might be worth > giving it a try. Do you guys believe that a change in wrapper could > improve my situation? Thanks! (Disclosure: I am

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Simon Slavin
On 8 Sep 2014, at 6:27pm, Roger Binns wrote: > The problem with synchronous off is that all your code has to be perfect, Hmmm. How about this. Stop turning synchronous off for a month or two and see if people stop reporting the fault. Simon.

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Roger Binns
On 08/09/14 03:29, Andres Riancho wrote: > In my project we use the database to store data during the process > life, and then remove it when the process finishes. It sounds like what you could use temporary tables and let SQLite do the work for you. > With this in mind, sync=OFF still looks

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Simon Slavin
On 8 Sep 2014, at 11:47am, Andres Riancho wrote: > On Sun, Sep 7, 2014 at 11:39 PM, Simon Slavin wrote: > >> There are two possibilities: >> >> A) The database really is malformed >> B) The client's copy of SQLite is returning that code by

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Andres Riancho
Off-list some guys contacted me and mentioned APSW [0], another wrapper around sqlite for python, and said that it might be worth giving it a try. Do you guys believe that a change in wrapper could improve my situation? Thanks! [0] https://github.com/rogerbinns/apsw On Sun, Sep 7, 2014 at 11:11

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Andres Riancho
Simon, On Sun, Sep 7, 2014 at 11:39 PM, Simon Slavin wrote: > > On 8 Sep 2014, at 3:11am, Andres Riancho wrote: > >>I'm using sqlite as the database backend for an open source >> project and it works perfectly 99% of the time; however some

Re: [sqlite] Python - database disk image is malformed

2014-09-08 Thread Andres Riancho
Roger, On Mon, Sep 8, 2014 at 12:26 AM, Roger Binns wrote: > On 07/09/14 19:11, Andres Riancho wrote: >> * I'm setting [4] "PRAGMA synchronous=OFF" for increased >> performance. Can this trigger malformed errors? > > Read the doc: > >

Re: [sqlite] Python - database disk image is malformed

2014-09-07 Thread Roger Binns
On 07/09/14 19:11, Andres Riancho wrote: > * I'm setting [4] "PRAGMA synchronous=OFF" for increased > performance. Can this trigger malformed errors? Read the doc: https://sqlite.org/pragma.html#pragma_synchronous TLDR: yes To improve write performance use WAL:

Re: [sqlite] Python - database disk image is malformed

2014-09-07 Thread Simon Slavin
On 8 Sep 2014, at 3:11am, Andres Riancho wrote: >I'm using sqlite as the database backend for an open source > project and it works perfectly 99% of the time; however some users > have reported "database disk image is malformed" errors [1][2]. There are two

[sqlite] Python - database disk image is malformed

2014-09-07 Thread Andres Riancho
List, I'm using sqlite as the database backend for an open source project and it works perfectly 99% of the time; however some users have reported "database disk image is malformed" errors [1][2]. At the moment the w3af project has a really clean wrapper around sqlite [3] which allows