Skip to main content

PostgreSQL schema evolution with built-in multi-agent coordination ๐Ÿ“

Project description

Confiture ๐Ÿ“

PostgreSQL migrations with multi-agent coordination and 4 flexible strategies

Build fresh databases in <1 second. Zero-downtime migrations. Multi-agent conflict detection. Production data sync with PII anonymization.

PyPI Tests Python 3.11+ PostgreSQL 12+ License: MIT


Why Confiture?

Problem: Traditional migration tools replay every migration on every build (slow, brittle, maintains technical debt).

Solution: DDL files are the single source of truth. Just execute your schema once. Fresh databases in <1 second.

Multi-Agent Safe: Automatic conflict detection prevents teams and agents from stepping on each other.


Quick Start

Installation

pip install fraiseql-confiture

Basic Usage

# Initialize project
confiture init

# Write schema DDL files
vim db/schema/10_tables/users.sql

# Build database (<1 second)
confiture build --env local

# Generate and apply migrations
confiture migrate generate --name "add_bio"
confiture migrate up

Team Workflow (Multi-Agent)

# Register intention before making changes
confiture coordinate register --agent-id alice --tables-affected users

# Check for conflicts (by other agent)
confiture coordinate check --agent-id bob --tables-affected users
# โš ๏ธ Conflict: alice is working on 'users'

# Complete when done
confiture coordinate complete --intent-id int_abc123

Core Features

๐Ÿ› ๏ธ Four Migration Strategies

Strategy Use Case Command
Build from DDL Fresh DBs, testing confiture build --env local
Incremental Existing databases confiture migrate up
Production Sync Copy prod data (with anonymization) confiture sync --from production --anonymize users.email
Zero-Downtime Complex migrations via FDW confiture migrate schema-to-schema

๐Ÿค Multi-Agent Coordination

  • โœ… Automatic conflict detection
  • โœ… Intent registration and tracking
  • โœ… JSON output for CI/CD
  • โœ… <10ms per operation

๐ŸŒฑ Seed Data Management

  • โœ… Sequential execution (solves PostgreSQL parser limits on 650+ row files)
  • โœ… Per-file savepoint isolation for error recovery
  • โœ… Continue-on-error mode (skip failed files)
  • โœ… Prep-seed validation (5-level orchestrator)
  • โœ… 5-level validation (static โ†’ full execution)
  • โœ… Catch NULL FKs before production
  • โœ… Pre-commit safe (Levels 1-3)
  • โœ… Database validation with SAVEPOINT safety

๐Ÿ” Git-Aware Validation

  • โœ… Detect schema drift vs. main branch
  • โœ… Enforce migrations for DDL changes
  • โœ… Pre-commit hook support

๐Ÿ”ง Developer Experience

  • โœ… Dry-run mode (analyze before applying)
  • โœ… Migration hooks (pre/post)
  • โœ… Schema linting
  • โœ… PII anonymization
  • โœ… Optional Rust extension
  • โœ… Python 3.11, 3.12, 3.13

Documentation

Getting Started: docs/getting-started.md

Guides:

API Reference: docs/reference/

Examples: examples/


Project Status

โœ… v0.4.0 (February 4, 2026) - RELEASED

Phase 9 Addition (v0.4.0):

  • โœ… Sequential seed execution (solves PostgreSQL parser limits on 650+ row files)
  • โœ… Per-file savepoint isolation for error recovery
  • โœ… Continue-on-error mode for partial seeding
  • โœ… 29 new tests for seed workflow
  • โœ… Comprehensive documentation with 8 examples
  • โœ… Real database integration testing

What's Implemented:

  • โœ… All 4 migration strategies
  • โœ… Sequential seed execution with savepoints (NEW in v0.4.0)
  • โœ… Multi-agent coordination (production-ready, 123+ tests)
  • โœ… Prep-seed validation (5 levels, 98+ tests)
  • โœ… Git-aware schema validation
  • โœ… Schema diff detection
  • โœ… CLI with rich output
  • โœ… Comprehensive tests (4,100+)
  • โœ… Complete documentation

โš ๏ธ Beta Software: All features implemented and tested, but not yet used in production. Use in staging/development first.


Contributing

git clone https://github.com/fraiseql/confiture.git
cd confiture
uv sync --all-extras
uv run pytest

See CONTRIBUTING.md and CLAUDE.md.


Author & License

Vibe-engineered by Lionel Hamayon ๐Ÿ“

MIT License - Copyright (c) 2025 Lionel Hamayon


Making jam from strawberries, one migration at a time. ๐Ÿ“โ†’๐Ÿฏ

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fraiseql_confiture-0.5.8.tar.gz (1.4 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

fraiseql_confiture-0.5.8-cp314-cp314-win_amd64.whl (706.9 kB view details)

Uploaded CPython 3.14Windows x86-64

fraiseql_confiture-0.5.8-cp313-cp313-win_amd64.whl (706.9 kB view details)

Uploaded CPython 3.13Windows x86-64

fraiseql_confiture-0.5.8-cp313-cp313-manylinux_2_28_x86_64.whl (798.8 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

fraiseql_confiture-0.5.8-cp313-cp313-macosx_11_0_arm64.whl (753.4 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

fraiseql_confiture-0.5.8-cp312-cp312-win_amd64.whl (707.0 kB view details)

Uploaded CPython 3.12Windows x86-64

fraiseql_confiture-0.5.8-cp312-cp312-manylinux_2_28_x86_64.whl (798.9 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

fraiseql_confiture-0.5.8-cp312-cp312-macosx_11_0_arm64.whl (753.4 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

fraiseql_confiture-0.5.8-cp311-cp311-win_amd64.whl (706.7 kB view details)

Uploaded CPython 3.11Windows x86-64

fraiseql_confiture-0.5.8-cp311-cp311-manylinux_2_28_x86_64.whl (800.3 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

fraiseql_confiture-0.5.8-cp311-cp311-macosx_11_0_arm64.whl (753.7 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

File details

Details for the file fraiseql_confiture-0.5.8.tar.gz.

File metadata

  • Download URL: fraiseql_confiture-0.5.8.tar.gz
  • Upload date:
  • Size: 1.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8.tar.gz
Algorithm Hash digest
SHA256 61632c59b69d6de5e344a87a1ec4ee4eaca68b421fb797e52465f613780928ed
MD5 4721053fa4f357c1eb5c3f2d53afa095
BLAKE2b-256 977abedcfbe254416e1f96e7de2403d26677367dc20ac58afb3d5015e90e9041

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 706.9 kB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 1659ba322fa9050a2134592c2052465d3a19bd959773fb190bdb658d46fae79e
MD5 5505fa8167430194948c87b33bac6e98
BLAKE2b-256 45f8c51b7deb397b3b8b63b7e1cde5bedcfe2717e042805a6c292f3cb0afb147

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 706.9 kB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 ac63d63654df08cda3e46669b2a3a7c4461712949c1bb99e849c8311991ef867
MD5 c0c763cd37099e05b70ce668e3c8ce6e
BLAKE2b-256 6fd19915ce0e2e9d419ac8959b64970d243ef2602663e241a8902955855d7124

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp313-cp313-manylinux_2_28_x86_64.whl
  • Upload date:
  • Size: 798.8 kB
  • Tags: CPython 3.13, manylinux: glibc 2.28+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 12cd3f5cdb63d1c38c323fc988e0fa0eed4800a3018a112f951accb525becc0b
MD5 e5fff85afd2d63ea6146e5e96d042f66
BLAKE2b-256 b21fef7d8119614f954b1366ad9b8c78244e5c089adb3375ec0ff9f7e71599cf

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp313-cp313-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 753.4 kB
  • Tags: CPython 3.13, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a5666a6e0c068ed75296484b6e8544c129f53010e296073ebd08260ede6cfff9
MD5 466e22e1a045996d244eb19a7c2b01df
BLAKE2b-256 b9aecacab2ed6abcd94deed1c47675bdca21ab8e312d29e50a08e89f7c2eef71

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 707.0 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 65ab2d68302370c8961ced24921735f75e774aa672d177f03f5c928b6434f885
MD5 657420bed81ba2b8efcca5ae8a49a377
BLAKE2b-256 432abd393d11e2807aa920080de0b40369f99ae886d05238b777ac66e6bf91f0

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp312-cp312-manylinux_2_28_x86_64.whl
  • Upload date:
  • Size: 798.9 kB
  • Tags: CPython 3.12, manylinux: glibc 2.28+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 55d4a970d0b8982baf2392c18c442a1d691321effef1ff343e79d2cf8b24206b
MD5 6b30a0de224723fc3c0b1e9614a2620d
BLAKE2b-256 f3d356348f763b7a98398bc0b661b466e7e13b01cd9b8325770fbebd3568df64

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp312-cp312-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 753.4 kB
  • Tags: CPython 3.12, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a57bc2a2d43c36930f4633e0409823dd84679aad009d931de7487e919ce49414
MD5 74ca3c016da083b3ebd127142c5ce182
BLAKE2b-256 960cd9721e71b9db8df01a7d8ae5fed1ca080741c7576a135c1191b9d4f61150

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 706.7 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 1ec79892203f6ca78629c42df24a23529e6d10b832f2164f91f663a9afc20973
MD5 6c6562f0c953c88f176ebc3781795aa2
BLAKE2b-256 598c94367562409c7cea7abdb5b1d1b72d029b979f4b56e88857d8947023a44b

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp311-cp311-manylinux_2_28_x86_64.whl
  • Upload date:
  • Size: 800.3 kB
  • Tags: CPython 3.11, manylinux: glibc 2.28+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 4337180a25ef1de784853c6061bec070fc324493eb171516d8e3f7ca34bcb99f
MD5 98c163acbbe3dc0f2a91537ea1ddbc52
BLAKE2b-256 77c833c0a1fb26e227cdeffde005429bd3452e70e3bcf941e28c77a37f6a1da8

See more details on using hashes here.

File details

Details for the file fraiseql_confiture-0.5.8-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

  • Download URL: fraiseql_confiture-0.5.8-cp311-cp311-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 753.7 kB
  • Tags: CPython 3.11, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","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}

File hashes

Hashes for fraiseql_confiture-0.5.8-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b0ecc3550c059657ded0b23174681ed98336244cebaaedb0120e49465c2cedba
MD5 5fbf77e7e529d15743e08e7b6bd62284
BLAKE2b-256 3586957c54e2d0bf702c3d3c4195ba2051f9185a2ed99d5024b4dfcce5d1d05f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page