Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

datasette-otel-file-exporter

Export Datasette's builtin OpenTelemetry data into NDJSON or Parquet files, to the disk or to S3.

Many tools that read OTel data can be expensive or impractical to run for small Datasette deployments. You could run Honeycomb or Grafana alongside your Datasette instances, but a constantly-running service adds up. The datasette-otel-file-exporter plugin sidesteps this, saving OTel data cheaply to your filesystem or S3. If you need to debug a slow Datasette instance or inspect some logs, you can retrieve your traces from the exported files.

Installing

This plugin requires Datasette 1.0a41 or higher.

uv add datasette-otel-file-exporter

# parquet support, default is gzip'ed NDJSON files
uv add datasette-otel-file-exporter[parquet]

# S3 support, default is filesystem
uv add datasette-otel-file-exporter[obstore]

Usage

A one-liner with uvx:

uvx --prerelease=allow \
  --with datasette-otel-file-exporter \
  --with 'datasette>=1a41' \
  datasette \
    -s plugins.datasette-otel-file-exporter.path ./telemetry \
    my_data.db

After a few seconds of traffic, datasette-otel-file-exporter will begin to export OpenTelemetry traces as gzip'ed NDJSON files to the telemetry/ directory.

› tree telemetry
telemetry
└── traces
    └── 2026
        └── 09
            └── 24
                └── 21
                    ├── 1790284044926-96db28b2.ndjson.gz
                    ├── 1790284064949-6c93d218.ndjson.gz
                    └── 1790284567838-5cfff753.ndjson.gz

You can query this data with any analytical tool. Here's an example query with DuckDB:

> from read_json_auto('telemetry/traces/**/*.ndjson.gz');
┌────────────────┬─────────────────────────────────┬──────────────────┬──────────────────┬───┬──────────────────────┬──────────────────────┬────────┬────────┐
│ schema_version │            trace_id             │     span_id      │  parent_span_id  │ … │      attributes      │       resource       │ events │ links  │
│     int64      │             varchar             │     varchar      │     varchar      │ … │ struct("db.system" … │ struct("telemetry.s… │ json[] │ json[] │
├────────────────┼─────────────────────────────────┼──────────────────┼──────────────────┼───┼──────────────────────┼──────────────────────┼────────┼────────┤
│              1 │ 268abc18c6dbb29f746d196df9d404… │ 1ee8e06fb218a279 │ eb9aa742efee8c68 │ … │ {'db.system': NULL,… │ {'telemetry.sdk.lan… │ []     │ []     │
│              1 │ 268abc18c6dbb29f746d196df9d404… │ eb9aa742efee8c68 │ NULL             │ … │ {'db.system': sqlit… │ {'telemetry.sdk.lan… │ []     │ []     │
│              · │                ·                │        ·         │        ·         │ … │ ·                    │          ·           │ ·      │ ·      │
│              1 │ 9b2a6a045305ebe32ce0c9107c3512… │ 7cf2943e9b815d56 │ NULL             │ … │ {'db.system': NULL,… │ {'telemetry.sdk.lan… │ []     │ []     │
└────────────────┴─────────────────────────────────┴──────────────────┴──────────────────┴───┴──────────────────────┴──────────────────────┴────────┴────────┘

Parquet files are supported as well, but require the [parquet] extra and the format config option:

uvx --prerelease=allow \
  --with datasette-otel-file-exporter[parquet] \
  --with 'datasette>=1a41' \
  datasette \
    -s plugins.datasette-otel-file-exporter.path ./telemetry \
    -s plugins.datasette-otel-file-exporter.format parquet \
    my_data.db

And instead of writing to the filesystem, you can opt-in and configure datasette-otel-file-exporter to write to an S3 bucket, with the [obstore] extra and the url config option:

export AWS_ACCESS_KEY_ID=...
export AWS_SECRET_ACCESS_KEY=...
export AWS_REGION=...
uvx --prerelease=allow \
  --with datasette-otel-file-exporter[parquet,obstore] \
  --with 'datasette>=1a41' \
  datasette \
    -s plugins.datasette-otel-file-exporter.url s3://my-bucket/telemetry \
    -s plugins.datasette-otel-file-exporter.format parquet \
    my_data.db

More configuration options, including setting access keys in configuration instead of environment variables, are in the Configuration Reference.

Privacy

The exported files include the text of SQL queries Datasette runs, and on a public instance that includes SQL sent by visitors. Parameter values are never recorded. Treat the telemetry directory or bucket with the same care as the database itself. See Privacy.

More

  • Documentation: file format, schema and every configuration option
  • Cookbook: jq and DuckDB recipes for slow queries, request rates, trace trees and more

Release files for datasette-otel-file-exporter 0.1.0a1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for datasette-otel-file-exporter 0.1.0a1
File Size Uploaded
datasette_otel_file_exporter-0.1.0a1.tar.gz 36.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for datasette-otel-file-exporter 0.1.0a1
File Interpreter ABI Platform
datasette_otel_file_exporter-0.1.0a1-py3-none-any.whl Python 3 none any Details

Total release size: 60.3 kB

Release files / datasette_otel_file_exporter-0.1.0a1.tar.gz

Download URL datasette_otel_file_exporter-0.1.0a1.tar.gz
Size 36.5 kB
Tags Source
SHA-256 checksum
How to use checksums
e83e2f116470a94c4d725abb5a73135b216e6361701ea0657de690d54e98ddf4
BLAKE2b-256 checksum
How to use checksums
30d95fba855b2928f79ea30017e96a353834a4b1d216c3127cb75b5f5bce448a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 25, 2026.

Transparency log

Release files / datasette_otel_file_exporter-0.1.0a1-py3-none-any.whl

Download URL datasette_otel_file_exporter-0.1.0a1-py3-none-any.whl
Size 23.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5b41a88f7f0ff196be83f2dd9c5f0d1bf27efd51b6e35cbc6cba7b1e4dff88f5
BLAKE2b-256 checksum
How to use checksums
62c7e91098ee8f8785554a3495dd96bcae96f5c5a01816f8d6c88ca4b6d1040d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 25, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0a1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page