Changelog¶
All notable changes to DBPort are documented here. Every published version receives a changelog entry.
Each entry includes: version number, release date, and a summary of changes grouped by category.
0.1.0 — 2026-03-18¶
First public release. Published to PyPI and GitHub Pages.
Added¶
- PyPI publishing workflow — new
release.ymlworkflow triggered on version tags; builds sdist and wheel, smoke-tests the installed package, and publishes to PyPI via trusted publishing (OIDC) - Package artifact verification in CI — new
packagejob inci.ymlbuilds the distributable, installs it in a clean venv, and verifiesfrom dbport import DBPortanddbp --versionwork from the packaged artifact - Example smoke tests in CI — new
examplesjob validates Python example syntax (py_compile), CLI example syntax (bash -n), and alldbphelp commands - Comprehensive release checklist —
docs/versions/release-versioning.mdexpanded with pre-release, build verification, publish, and post-release verification steps
Changed¶
- CI coverage enforcement — test job now runs
pytest --cov --cov-report=term-missing, enforcing thefail_under = 95gate declared inpyproject.toml - Development status classifier — updated from
2 - Pre-Alphato3 - Alphainpyproject.toml
Fixed¶
- Deterministic credential resolution — added
autousefixture to credential tests that clears all credential env vars (ICEBERG_*,AWS_*,S3_*) and escapes the repo-root.envfile before each test; credential tests now pass reliably regardless of ambient environment dbp status checkcredential reporting — removed manualos.environfallback in the except branch; now reports a single clear message whenWarehouseCredsvalidation fails instead of re-inspecting env vars independently
0.0.9 — 2026-03-18¶
Homepage UX and publication-facing docs polish.
Changed¶
- Homepage redesigned — expanded from 4 to 6 cards aligned to the docs information architecture (Getting Started, Concepts, CLI Reference, Python API, Examples, Changelog); cards use documentation-first descriptions instead of marketing copy
- Homepage content trimmed — removed the "Key features" section; the card grid and quick example now serve as the sole entry points; hero text shortened to a single sentence
- Quick example uses content tabs — CLI and Python examples are now presented in
=== "CLI"/=== "Python"tabs instead of sequential blocks - Homepage TOC kept hidden — confirmed
hide: tocis the correct choice for a card-grid landing page (no long-form headings to navigate)
Improved¶
- Lock file page uses Zensical teaching patterns — added code annotations (
(1)!syntax) to the annotated TOML example with inline explanations for each section; replaced plain-text correctness warnings with!!! warningadmonition; replaced merge conflict resolution list with!!! tipadmonition; improved visual scanability without custom hacks - Inputs page enhanced — added Mermaid flow diagram for the Arrow ingestion pipeline; snapshot caching force-refresh note moved to
!!! tipadmonition; input tracking details moved to!!! infoadmonition - Outputs page enhanced —
SchemaDriftErrorexample now uses code annotations explaining each diff symbol (+,-,~); idempotency note consolidated into!!! infoadmonition - Metadata page enhanced — chaining example uses code annotation explaining the return-self pattern; storage mechanism highlighted with
!!! infoadmonition - Hooks page enhanced — hook resolution order wrapped in
!!! noteadmonition for reference visibility; trust model wrapped in!!! warningadmonition for security emphasis - Versioning page enhanced — pre-publish checks wrapped in
!!! warningadmonition; streaming Arrow fallback wrapped in!!! infoadmonition - Concepts index page enhanced — ASCII mental model diagram replaced with Mermaid
graph LRflow diagram using brand colors
0.0.8 — 2026-03-17¶
Zensical navigation model and brand alignment.
Changed¶
- Homepage navigation restored — removed
hide: navigationfrom the homepage so the left sidebar is visible on all pages, including the landing page - Left navigation expanded by default — added
navigation.expandso section subpages are visible in the sidebar without clicking to expand - Brand palette applied — switched theme palette from
deep purple/amberto brand-alignedindigo/deep-orangebase, with exact brand color overrides viadocs/stylesheets/brand.css(Harbor Blue#1F4E79, Signal Coral#E07A5F, dark mode backgrounds from brand guide) - Brand typography configured — set Inter as the text font and JetBrains Mono as the code font via
[project.theme.font], matchingdocs/brand.md
Added¶
docs/stylesheets/brand.css— custom property overrides for light and dark mode using the brand design tokens fromdocs/brand.md
Confirmed¶
- Right sidebar TOC preserved — explicitly confirmed
toc.integrateis not enabled andtoc.followremains active, keeping the intended three-column layout (tabs + left nav + right TOC) - Logo unchanged —
lucide/fishing-hookicon matches the brand guide; no change needed - Zensical-native only — all changes use documented Zensical/Material capabilities (
extra_css,--md-*properties,theme.font); no custom template overrides or JavaScript
0.0.7 — 2026-03-17¶
Execution model and conceptual docs depth.
Added¶
- Hooks concept page — new
docs/concepts/hooks.mddocumenting hook resolution order, Python vs SQL hooks,execvsrunvspublishsemantics, and the trust model - Lock file operator guide — expanded
docs/concepts/lock-file.mdwith annotated structure examples, a mutation table (which operation changes what), diff walkthroughs for schema changes / snapshot updates / new publishes, and recovery procedures for merge conflicts, stale files, and manual edits
Changed¶
- Publish safety — catalog connection failures (
OSErrorsubclasses likeConnectionError,TimeoutError) during the pre-publish schema drift check now raiseRuntimeErrorinstead of being logged as warnings. Non-network errors continue to warn and proceed. The schema service's drift check remains advisory (warn-only) since it should not block local development - Hook execution —
_exec_python_hooknow raises a clearFileNotFoundErrorwith remediation guidance when the resolved hook file does not exist, instead of deferring to a confusingpath.read_text()error - Hook trust model — module docstring in
run.pynow explicitly documents thatexec()is deliberate and hook files are trusted code - Section index pages — all four section landing pages (Getting Started, Concepts, API Reference, Examples) now include "start here" orientation guidance
- Cross-links — Python API, CLI reference, and Python workflow example pages now link to the new hooks concept page
0.0.6 — 2026-03-17¶
Public package surface and repository trustworthiness.
Added¶
- Package surface contract tests —
test_no_version_attribute,test_version_via_importlib, andtest_no_internal_symbols_leakintest_contract.pyensure onlyDBPortis exported and version is accessed viaimportlib.metadata - PyPI-facing metadata —
pyproject.tomlnow includeslicense,authors,keywords,classifiers, and[project.urls](Homepage, Documentation, Repository, Changelog) - CONTRIBUTING.md — development setup, code style, architecture overview, and PR guidelines
- SECURITY.md — vulnerability reporting via GitHub Security Advisories, response timeline, and scope
- Docs artifact policy — documented in
docs/release-versioning.md:site/belongs ongh-pagesonly,_preview/is git-ignored, source markdown lives onmain
Changed¶
- README.md rebuilt — removed stale
setup.shreference, corrected DuckDB extension install description (automatic at runtime, not pre-installed), replaced inline API overview with links to the docs site, updated project structure to match current layout - Section index pages — each docs section (API, Concepts, Examples, Getting Started) now has a distinct lead sentence and cross-references to related sections
0.0.5 — 2026-03-17¶
CLI reference and executable workflows.
Added¶
- CLI contract tests — 18 tests in
test_cli_contract.pythat lock thedbpcommand tree: top-level commands, global options, status/model/config subcommands, all command flags, and absence of stale references - Model and version resolution contract tests — 22 tests in
test_resolution_contract.pythat lock the 5-step model resolution precedence, 3-step version resolution forrun, 2-step version resolution forpublish, and the intentional difference between the two strategies - Exit code contract — exit code 0 for success, 1 for user/validation errors, 2 for internal/unexpected errors, 130 for interrupts;
CliUserErrorexception class for explicit validation failures - JSON error typing —
--jsonerror output now includes anerror_typefield (runtime_error,file_not_found,validation_error,internal_error,interrupted) for automation - Exit codes documented — CLI reference now includes an exit code table
Changed¶
- Stale
dbp project syncremoved —dbp initno longer references the removeddbp project synccommand; guidance now points todbp model sync - Stale
dbp load/dbp runremoved —dbp initoutput now shows correctdbp model loadanddbp model runcommands - Generic errors now exit 2 — unexpected/internal errors now use exit code 2 instead of 1, distinguishing them from user errors
Fixed¶
- CLI reference rebuilt —
docs/api/cli.mdnow documents the actual nestedconfig default model/folder/hookandconfig model MODEL_KEY version/input/schema/columnshierarchy; added missing--messageflag on publish,--timingon exec/run,dbp status checksection, version resolution documentation, and exit code table - CLI example fixed —
examples/minimal_cli/run.shremoved staledbp project syncanddbp status --show-history; all commands verified against the current CLI - Stale
dbp config checkreferences fixed —docs/examples/cli-workflow.mdanddocs/getting-started/credentials.mdnow correctly referencedbp status check - Stale
dbp config defaultreference fixed —docs/examples/cli-workflow.mdnow uses the correctdbp config default modelsyntax
0.0.4 — 2026-03-17¶
Python API reference correctness.
Added¶
- Complete Python API reference — documented
model_root,load_inputs_on_init,config_onlyconstructor parameters; documentedport.configure_input(),port.run(), andport.run_hook; added sections for initialization behavior, full mode vs.config_only, hook resolution, and the relationship betweenload()andconfigure_input() - Python client contract tests — 33 tests in
test_contract.pythat lock the publicDBPortsurface: module exports, constructor signature, public method/property inventory, method signatures,config_onlyguards, return types, and initialization behavior - Initialization behavior documentation — documented the four init phases (path resolution, credential resolution, adapter wiring, state sync) and the error resilience guarantees for each sync step
Changed¶
- Sync output warning level —
_sync_output_state()errors now log at warning level instead of debug, since a failed output table creation is user-relevant - FetchService error logging —
FetchService.execute()now logs failedlast_fetched_atupdates at debug level instead of silently swallowing exceptions
Improved¶
- Init method docstrings — added detailed docstrings to
__init__,_auto_detect_schema,_sync_output_state,_load_inputs, and_update_last_fetcheddocumenting their behavior, error handling, and guarantees
0.0.3 — 2026-03-17¶
Version policy and release planning language.
Added¶
- Release versioning policy — new
docs/release-versioning.mdpage documenting the project'sX.Y.Znumbering convention (major / normal / minor), the predevelopment milestone path from0.0.1to0.1.0, the single source of truth inpyproject.toml, and the per-version release checklist - Release Versioning added to docs site navigation
Fixed¶
- CLI version fallback —
dbp --versionno longer reports a hard-coded"0.1.0"when package metadata is unavailable; now reports"unknown"instead of a misleading future version
0.0.2 — 2026-03-17¶
Release history and roadmap foundations.
Added¶
- Changelog page — first-class changelog in the docs site, structured around versions
- Roadmap page — milestone-based roadmap covering package, CLI, runtime, docs, release, and testing
0.0.1 — 2026-03-16¶
Foundation release. Establishes the full runtime, architecture, CLI, documentation site, and CI pipeline.
Core runtime¶
- Single public import —
from dbport import DBPortis the only supported entry point - Hexagonal architecture — domain (entities + ports), application (services), adapters (concrete implementations), wired in
DBPort.__init__ - Context manager —
with DBPort(...) as port:for automatic resource cleanup - Constructor with optional kwargs for all credentials and paths; falls back to
.envthen environment variables - Config-only mode —
DBPort(config_only=True)for lightweight initialization without warehouse connection
Data operations¶
port.schema(ddl_or_path)— declare output table from inline DDL or.sqlfile; creates table in DuckDB and persists columns to lockport.load(table_address, filters=...)— load Iceberg tables into DuckDB via Arrow C++ multi-threaded parquet reader; snapshot-cached (skips unchanged tables)port.configure_input(table_address, ...)— validate and persist input declaration without loading dataport.execute(sql_or_path)— run inline SQL or.sqlfiles in DuckDBport.run()— execute configured run hooks (Python or SQL)port.publish(version, params, mode)— write output to Iceberg with full metadata and codelist attachment; supports idempotent, dry, and refresh modes
Column metadata¶
port.columns.<name>.meta(...)— override codelist metadata per column (codelist ID, type, kind, labels); persists immediately to lockport.columns.<name>.attach(table=...)— use a loaded DuckDB table as the codelist source for a column
Write strategy¶
- DuckDB-first publish — uses the DuckDB
icebergextension as the primary write path - Streaming Arrow fallback — auto-switches to 50K-row Arrow batches when the catalog lacks multi-table commit support; per-batch checkpoints, conflict retry with resume
- Schema drift protection — fail-fast comparison of local vs warehouse schema before any write
- Idempotent publish — checkpoint tracking via Iceberg table properties (
dbport.upload.v2.<version>.completed)
Metadata lifecycle¶
- Fully automatic metadata management:
created_at,last_updated_at,last_fetched_at, inputs, codelists, versions - In-memory
metadata.jsongeneration (gzip+base64, embedded in Iceberg table properties) - In-memory codelist CSV generation from DuckDB (embedded in Iceberg column docs)
- No intermediate files written to disk
Domain model¶
- Immutable value objects — all Pydantic frozen models:
Dataset,DatasetKey,DatasetSchema,SqlDdl,ColumnDef,DatasetVersion,VersionRecord,InputDeclaration,IngestRecord,CodelistEntry,ColumnCodelist - Port protocols —
ICatalog,ICompute,ILockStore,IMetadataStore
Adapters¶
- IcebergCatalogAdapter — DuckDB-first data ops with pyiceberg for metadata; S3-compatible object stores
- DuckDBComputeAdapter — file-backed DuckDB with auto-extension loading (
iceberg,httpfs,avro) - TomlLockAdapter —
dbport.lockTOML file at repo root; multi-model, credential-free, committable - MetadataAdapter — in-memory metadata JSON builder with version-aware
created_atpreservation - Codelist adapters — CSV generation from output columns and attached tables
- Attach adapter — gzip+base64 metadata and codelist embedding into Iceberg table properties
- Schema drift checker — PyArrow schema comparison with detailed diff reporting
- Ingest cache — snapshot ID comparison to skip unchanged tables
Application services¶
IngestService— snapshot resolution, cache check, Arrow-streamed loadTransformService— SQL execution from strings or filesDefineSchemaService— DDL parsing, DuckDB table creation, lock persistencePublishService— schema validation, idempotent write, metadata+codelist attachmentFetchService—last_fetched_atupdate on initAutoSchemaService— warehouse schema auto-detection with Arrow-to-DuckDB type mappingSyncService— local DuckDB sync from lock file stateRunService— hook execution (Python and SQL) with auto-detection
CLI¶
dbpcommand with global options:--version,--project,--lockfile,--model,--verbose,--quiet,--json,--no-colordbp init— scaffold a new model with template filesdbp status— show project state, inputs, versions, lock contentdbp model sync|load|execute|publish— full model lifecycle commandsdbp config— environment and credential managementdbp schema— output schema managementdbp check— configuration validation- Rich console output — tables, trees, progress rendering, JSON mode
Infrastructure¶
WarehouseCreds— pydantic-settings credential resolution (kwargs →.env→ env vars)setup_logging()— Rich logging with stdlib fallback; silences noisy third-party loggers- Progress callbacks — context-variable-based progress protocol for CLI integration
Documentation site¶
- Zensical-powered docs with deep purple + amber theme, light/dark mode toggle
- Getting Started — installation, credentials, quickstart
- Concepts — inputs, outputs, metadata, lock file, versioning & publish
- API Reference — Python client API, CLI commands
- Examples — Python workflow, CLI workflow
- Versioned deployment — mike-compatible directory structure (
/<version>/,/latest/,versions.json) - Local preview —
scripts/preview_docs.shbuilds a real versioned tree in_preview/
Testing¶
- 920+ tests across 41 test modules mirroring the source layout
- 95% coverage requirement enforced in
pyproject.toml - Uses
_Fake*test doubles andtmp_pathfixtures - Covers domain entities, all adapters, all services, CLI commands, and infrastructure
CI/CD¶
- CI workflow — pytest on Python 3.11 and 3.12, ruff lint + format check, docs build verification
- Docs workflow — tag-triggered GitHub Pages deployment with version validation against
pyproject.toml scripts/update_versions.py— manages multi-versionversions.jsonduring deployment
Examples¶
examples/minimal/main.py— full Python client API usage (schema, meta, attach, load, execute, publish modes)examples/minimal_cli/run.sh— full CLI-driven workflow with all commands