Back to TILs.

Calmcode TIL

PySqlite3 logoPySqlite3

I wanted to get the most recent version of sqlite3 on my machine in order to play with sqlite-vec. It took a small hoop to get it working on my mac, but when it was time to install it on my linux machine I found a much easier way.

python -m pip install pysqlite3-binary

This pysqlite3 package carries a binary distribution of sqlite3 and it always tries to carry the most recent version. From here you can use this new version as you would normally use sqlite3. So instead of doing this:

import sqlite3

db = sqlite3.connect(":memory:")

You would do this:

import pysqlite3

db = pysqlite3.connect(":memory:")

Pretty easy and hassle free.


Back to main.