Skip to content

Quickstart

Pre-releases ship PotluckDB as a drop-in SQLite library: programs that use SQLite load it in place of their usual one. Nothing syncs yet; sync comes in later releases (what works today).

From Python, the quickest start is the package:

Terminal window
pip install --pre potluckdb
python -c "import potluckdb as sqlite3; print(sqlite3.connect(':memory:').execute('select potluckdb_version()').fetchone())"

See Python, Node.js, Rust, Go and .NET. For any other program, use the library directly:

Get the archive for your platform from the releases page (see platforms for the names), and check it if you like. Then unpack it:

Terminal window
tar xzf potluckdb-sqlite-<version>-linux-x64-gnu.tar.gz

Each archive holds the library (lib/, or bin/ on Windows), its headers (include/) and its licence.

Python’s built-in sqlite3 module is a quick way to try it. Point it at the library and ask which build answers:

Terminal window
# Linux
LD_LIBRARY_PATH=$PWD/potluckdb-sqlite-<version>-linux-x64-gnu/lib \
python3 -c "import sqlite3; print(sqlite3.connect(':memory:').execute('select potluckdb_version(), sqlite_version()').fetchone())"
Terminal window
# macOS, with Homebrew's Python (python.org's builds have SQLite built in)
DYLD_LIBRARY_PATH=$PWD/potluckdb-sqlite-<version>-macos-arm64/lib \
/opt/homebrew/bin/python3 -c "import sqlite3; print(sqlite3.connect(':memory:').execute('select potluckdb_version(), sqlite_version()').fetchone())"

It prints the PotluckDB and SQLite versions, for example ('0.8.0-dev.1', '3.54.1'). A plain SQLite has no potluckdb_version() function, so the query fails if the program still uses its usual library.