Query a Flowfile catalog from DuckDB / Superset — zero-copy, read-only.
Project description
flowfile-duckdb
Query a Flowfile catalog from DuckDB (and anything that speaks DuckDB, like Apache Superset) — zero-copy, read-only.
Flowfile stores catalog tables as open Delta Lake tables (Parquet + _delta_log) and tracks them in a small SQLite database (flowfile_catalog.db). DuckDB reads Delta natively via delta_scan, so this package is a thin metadata bridge: it reads the SQLite catalog and exposes every table to DuckDB as a view over delta_scan(...) (or read_parquet(...) for legacy Parquet tables). No data is copied or moved; queries read the underlying files live.
Install
With uv (recommended):
uv pip install flowfile-duckdb # once published
uv pip install -e . # from a checkout
Or plain pip:
pip install flowfile-duckdb
CLI
flowfile-duckdb list # sanity-check discovered tables
flowfile-duckdb build --out catalog.duckdb # persist a DuckDB file with the views
flowfile-duckdb attach > init.sql # emit the CREATE VIEW SQL as an init script
Common flags: --catalog-db PATH, --schema-template, --include-cloud, --owner-id N.
Python
import duckdb
from flowfile_duckdb import attach_flowfile_catalog
con = duckdb.connect()
attach_flowfile_catalog(con) # schemas render as e.g. Demo_sales_analytics
con.sql('SELECT * FROM "Demo_sales_analytics"."sales" LIMIT 5')
Schema names default to {catalog}_{schema} (single underscore); override via
schema_template= (e.g. "{schema}" to drop the catalog prefix).
Where is the catalog DB?
Resolved the same way Flowfile resolves it:
FLOWFILE_DB_PATH— explicit path toflowfile_catalog.db.<FLOWFILE_STORAGE_DIR or ~/.flowfile>/database/flowfile_catalog.db(default).
The SQLite connection is opened read-only.
Apache Superset
pip install duckdb-engine
flowfile-duckdb build --out /data/flowfile_catalog.duckdb
Add a Superset database with SQLAlchemy URI duckdb:////data/flowfile_catalog.duckdb.
See examples/superset.md.
Publishing (maintainers)
Distribution is automated via GitHub Actions (.github/workflows/publish.yml),
using PyPI Trusted Publishing (OIDC — no API token stored):
- On PyPI, add a trusted publisher for this project: owner
edwardvaneechoud, repoflowfile-duckdb, workflowpublish.yml, environmentpypi. - Create a GitHub Environment named
pypi. - Push a
v*tag (or publish a GitHub Release) — the workflow builds withuvand publishes to PyPI.
git tag v0.1.0 && git push origin v0.1.0
Known limitations / next steps
- Cloud tables (
s3://,az://,gs://) are skipped unless--include-cloud, which also needs a DuckDBCREATE SECRET.flowfile_duckdb/secrets.pymaps a decrypted options dict toCREATE SECRETSQL but deliberately does not decrypt Flowfile's$ffsec$secrets (that needs Flowfile's master key + HKDF). - Virtual / SQL tables have no physical files and are skipped (they can't be read without Flowfile's engine).
- Refresh: views read live data, but the table list is a snapshot —
re-run
build/attachto pick up newly created tables. - On multi-user (docker-mode) installs the catalog holds every user's tables;
use
--owner-idto scope to one user.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file flowfile_duckdb-0.1.0.tar.gz.
File metadata
- Download URL: flowfile_duckdb-0.1.0.tar.gz
- Upload date:
- Size: 37.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e67ec2610ae62a73a58ee2f401265899b42bc017fefedbd0cec5f825452ae8c8
|
|
| MD5 |
0767855f8d5e6d1ce9ab19a0a6c83d54
|
|
| BLAKE2b-256 |
9cea4d4748ad6c2d958b6eb609a9eb4a792fb47f3027229a468be1af9d3da39b
|
Provenance
The following attestation bundles were made for flowfile_duckdb-0.1.0.tar.gz:
Publisher:
publish.yml on Edwardvaneechoud/flowfile-duckdb
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
flowfile_duckdb-0.1.0.tar.gz -
Subject digest:
e67ec2610ae62a73a58ee2f401265899b42bc017fefedbd0cec5f825452ae8c8 - Sigstore transparency entry: 2129855178
- Sigstore integration time:
-
Permalink:
Edwardvaneechoud/flowfile-duckdb@05b30415dc61f5e8e7cfa9e2b2cc4feb8d0ff012 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Edwardvaneechoud
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@05b30415dc61f5e8e7cfa9e2b2cc4feb8d0ff012 -
Trigger Event:
push
-
Statement type:
File details
Details for the file flowfile_duckdb-0.1.0-py3-none-any.whl.
File metadata
- Download URL: flowfile_duckdb-0.1.0-py3-none-any.whl
- Upload date:
- Size: 11.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
67571b8e1eaed896c42ffe479e96996335baca07996da7d000b47d37b595a57b
|
|
| MD5 |
308819cab30cd2922be41a441f4134cc
|
|
| BLAKE2b-256 |
4f1572f658bf418b7a207941270c8b2b26523d21457c6647d6c55e5a8ffdedfe
|
Provenance
The following attestation bundles were made for flowfile_duckdb-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on Edwardvaneechoud/flowfile-duckdb
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
flowfile_duckdb-0.1.0-py3-none-any.whl -
Subject digest:
67571b8e1eaed896c42ffe479e96996335baca07996da7d000b47d37b595a57b - Sigstore transparency entry: 2129855191
- Sigstore integration time:
-
Permalink:
Edwardvaneechoud/flowfile-duckdb@05b30415dc61f5e8e7cfa9e2b2cc4feb8d0ff012 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Edwardvaneechoud
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@05b30415dc61f5e8e7cfa9e2b2cc4feb8d0ff012 -
Trigger Event:
push
-
Statement type: