twitter-to-sqlite icon indicating copy to clipboard operation
twitter-to-sqlite copied to clipboard

Fall back to FTS4 if FTS5 is not available

Open hpk42 opened this issue 4 years ago • 3 comments

got this with version 0.21.1 from pypi. twitter-to-sqlite auth worked but then "twitter-to-sqlite user-timeline USER.db" produced a tracekback ending in "no such module: FTS5".

hpk42 avatar Jun 16 '20 10:06 hpk42

That means your version of SQLite is old enough that it doesn't support the FTS5 extension.

Could you share what operating system you're running, and what the output is that you get from running this?

python -c 'import sqlite3; print(sqlite3.connect(":memory:").execute("select sqlite_version()").fetchone()[0])'

I can teach this tool to fall back on FTS4 if FTS5 isn't available.

simonw avatar Jun 17 '20 17:06 simonw

It's the one with python3.7::

>>> sqlite3.sqlite_version
'3.11.0'

On Wed, Jun 17, 2020 at 10:24 -0700, Simon Willison wrote:

That means your version of SQLite is old enough that it doesn't support the FTS5 extension.

Could you share what operating system you're running, and what the output is that you get from running this?

python -c 'import sqlite3; print(sqlite3.connect(":memory:").execute("select sqlite_version()").fetchone()[0])'

I can teach this tool to fall back on FTS4 if FTS5 isn't available.

-- You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub: https://github.com/dogsheep/twitter-to-sqlite/issues/47#issuecomment-645512127

hpk42 avatar Jun 17 '20 17:06 hpk42

I've now figured out how to compile specific SQLite versions to help replicate this problem: https://github.com/simonw/til/blob/master/sqlite/ld-preload.md

Next step: replicate the problem!

simonw avatar Jun 17 '20 20:06 simonw