Skip to main content

SQLMesh GizmoSQL Adapter

A SQLMesh engine adapter for GizmoSQL - a database server that uses DuckDB as its execution engine and exposes an Arrow Flight SQL interface for remote connections.

sqlmesh-gizmosql-ci Supported Python Versions PyPI version PyPI Downloads

Installation

pip install sqlmesh-gizmosql

This will install sqlmesh and adbc-driver-gizmosql as dependencies.

As of v0.3.0, this adapter runs on adbc-driver-gizmosql 2.0, powered by the new native Go GizmoSQL ADBC driver — same API as before, with DDL/DML immediate execution, RETURNING support, gizmosql:// URIs, and OAuth/SSO provided by the shared Go driver library used across all languages.

Usage

1. Import the adapter

Simply import the package before using SQLMesh. The adapter registers itself automatically:

import sqlmesh_gizmosql  # Registers GizmoSQL adapter
from sqlmesh import Context

context = Context(paths="path/to/project")

2. Configure your connection

Add a GizmoSQL connection to your config.yaml:

gateways:
  my_gizmosql:
    connection:
      type: gizmosql
      host: localhost
      port: 31337
      username: your_username
      password: your_password
      database: my_database  # optional, default catalog
      use_encryption: true   # default: true (uses TLS)
      disable_certificate_verification: false  # for self-signed certs

3. Use SQLMesh as normal

sqlmesh plan
sqlmesh run

Configuration Options

Option Type Default Description
host str localhost GizmoSQL server hostname
port int 31337 GizmoSQL server port
username str None Authentication username (not needed with auth_type: external)
password str None Authentication password (not needed with auth_type: external)
database str None Default database/catalog
use_encryption bool True Use TLS encryption
disable_certificate_verification bool False Skip TLS cert verification
auth_type str None Authentication type (e.g., external for browser-based OAuth/SSO)
concurrent_tasks int 4 Max concurrent tasks
register_comments bool True Register model comments
pre_ping bool False Pre-ping connections

OAuth/SSO Authentication

GizmoSQL supports browser-based OAuth/SSO via auth_type: external. When using external auth, no username or password is needed — a browser window will open for authentication:

gateways:
  my_gizmosql:
    connection:
      type: gizmosql
      host: gizmosql.example.com
      port: 31337
      auth_type: external
      disable_certificate_verification: true  # for self-signed certs

Features

  • Arrow Flight SQL: Efficient data transfer using Arrow's columnar format
  • Full Catalog Support: Create, drop, and switch between databases
  • Transaction Support: Full transaction control via SQL statements
  • ADBC Bulk Ingestion: Fast data loading using Arrow-native bulk operations
  • DuckDB Compatibility: Uses DuckDB SQL dialect for query generation

Requirements

  • Python >= 3.10
  • SQLMesh >= 0.236.1
  • A running GizmoSQL server with DuckDB backend

Development

# Clone the repository
git clone https://github.com/gizmodata/sqlmesh-gizmosql.git
cd sqlmesh-gizmosql

# Install dev dependencies
pip install -e ".[dev]"

# Run tests
pytest

# Run linting
ruff check .
mypy sqlmesh_gizmosql

License

Apache 2.0

Metadata

Release files for sqlmesh-gizmosql 0.3.1

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

Source distribution (sdist)

Source distribution for sqlmesh-gizmosql 0.3.1
File Size Uploaded
sqlmesh_gizmosql-0.3.1.tar.gz 12.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sqlmesh-gizmosql 0.3.1
File Interpreter ABI Platform
sqlmesh_gizmosql-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 22.0 kB

Release files / sqlmesh_gizmosql-0.3.1.tar.gz

Download URL sqlmesh_gizmosql-0.3.1.tar.gz
Size 12.3 kB
Tags Source
SHA-256 checksum
How to use checksums
75e46aa30823d93b48de01d332a60cd4d3b211c47a8c57d5c745e3f9b2d57027
BLAKE2b-256 checksum
How to use checksums
de0b2fd7311384cd7b596e8d273cfd9eff213a704c1afbd73b96b43f5c3bc128
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 Aug 24, 2026.

Transparency log

Release files / sqlmesh_gizmosql-0.3.1-py3-none-any.whl

Download URL sqlmesh_gizmosql-0.3.1-py3-none-any.whl
Size 9.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b9ab1fd25781a48d31803c27a21a803d93d3eb5a65f382e0960c6fd4d7b0b671
BLAKE2b-256 checksum
How to use checksums
5c43ab999ba24fc1e921f7429ef663eec56223f5f8bfcfb09186cbac8f27d488
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 Aug 24, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.3.1 This release

2 release files

0.3.0

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.0

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