Skip to main content
Pre-release

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

deltaplan △

Declarative plan / apply for Databricks SQL tables. Describe your Unity Catalog tables in YAML, diff that against the live catalog, review a plan that knows which Delta changes are free and which rewrite 400 GB — then apply it.

ci Docs Python License: Apache-2.0 Ruff

Status: alpha. Every milestone in the design is built — plan, apply (rewrites included), drift, the GitHub Action, and governance (tags, grants, masks, row filters, views, SQL functions). It is tested offline against a fake warehouse, and every assumption it makes about Databricks is checked by a live suite against a real workspace. Try it on a dev catalog before production.

uv tool install --prerelease allow deltaplan   # or: pip install --pre deltaplan

Get started → — install, import a schema, plan, apply: ten minutes on your own workspace.

Take the tour → — one project from nothing to a reviewed pull request, every step shown — or browse the feature gallery. The docs have the spec format, the commands, and the safety model. docs/DESIGN.md is the source of truth.

The spec

table: ${catalog}.sales.orders
comment: Order facts
cluster_by: [order_date]
columns:
  - name: order_id
    type: bigint
    nullable: false
  - name: customer_ref
    type: string
    renamed_from: cust_id
  - name: address
    type:
      struct:
        - {name: street, type: string}
        - {name: zip, type: string}

Or as SQL — the same model, read with sqlglot:

CREATE TABLE ${catalog}.sales.customers (
  customer_id BIGINT NOT NULL,
  name        STRING,
  CONSTRAINT customers_pk PRIMARY KEY (customer_id)
)
CLUSTER BY AUTO;

A project can mix both. SQL specs support what sqlglot can parse; YAML supports everything — the list says which.

The plan

A deltaplan plan: a rename, a widening, a backfilled NOT NULL column, a nested field, a CHECK and a grant, each with its numbered, risk-labelled steps

Why

  • Delta-aware. Metadata-only, needs-a-table-feature, and full-rewrite are different things, and the plan says which one you're about to do — before you do it.
  • Safe by default. Only tables deltaplan manages are ever drop candidates; everything else is reported as unmanaged and left untouched. Destructive steps need --allow-destructive, and a stale plan is refused.
  • No state file. Unity Catalog is the state.
  • Nested types are first class. Struct, array and map fields diff by path (address.element.zip), including renames and per-field comments.
  • Reviewable. The plan is a data structure; the terminal, Markdown (for PR comments) and JSON renderers all read the same object.

Commands

deltaplan validate -t dev             # spec lint, no connection needed
deltaplan import main.sales -o tables # live tables -> YAML specs
deltaplan apply -t dev                # plan, show, ask, run
deltaplan plan -t dev [-o plan.json] [--select sales.orders] [--format rich|md|json]
deltaplan show plan.json -f md        # render a saved plan, no warehouse needed
deltaplan apply plan.json [--allow-destructive]   # run a reviewed plan, as CI does
deltaplan drift -t dev                # exit code 2 on drift, for CI
deltaplan force-unlock -t dev

In CI

- uses: misja-pronk/deltaplan@v0
  with:
    target: prod        # comments the plan on the pull request

Plan on pull requests, apply on merge, catch drift nightly — see the CI guide.

Development

deltaplan uses mise + the Astral stack (uv, ruff, ty).

mise install     # pinned Python + uv
uv sync          # .venv with deps and dev tools

mise run check   # lint + format check + types + unit tests
mise run test    # uv run pytest tests/unit
mise run docs    # preview the docs at localhost:8000

See CONTRIBUTING.md for the architecture and the house rules.

License

Apache-2.0 — see LICENSE.

Metadata

Release files for deltaplan 0.1.0a8

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

Source distribution (sdist)

Source distribution for deltaplan 0.1.0a8
File Size Uploaded
deltaplan-0.1.0a8.tar.gz 428.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for deltaplan 0.1.0a8
File Interpreter ABI Platform
deltaplan-0.1.0a8-py3-none-any.whl Python 3 none any Details

Total release size: 576.9 kB

Release files / deltaplan-0.1.0a8.tar.gz

Download URL deltaplan-0.1.0a8.tar.gz
Size 428.9 kB
Tags Source
SHA-256 checksum
How to use checksums
617772760326812ba2558be65017ed682ac3c8caa77847ad3f82ab884ff616d4
BLAKE2b-256 checksum
How to use checksums
02db1dbcbcd62c72fb8c9d684450daef477e87900e3063b629304a4936dc88d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.17 {"installer":{"name":"uv","version":"0.12.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / deltaplan-0.1.0a8-py3-none-any.whl

Download URL deltaplan-0.1.0a8-py3-none-any.whl
Size 147.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
44248c3d54254d51d32bdf9d7471e2094fb63143a89fc6ba3ee381dad73dd7c6
BLAKE2b-256 checksum
How to use checksums
8656003d39586ad1dd0c6c4a43628e820bf12a808fa9fb386274926e0c0626fd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.17 {"installer":{"name":"uv","version":"0.12.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
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