Skip to content

PostKit v1.0.9 Bugfix Release

Choose a tag to compare

@supunappri99 supunappri99 released this 27 Apr 16:10
d6873be

Release Notes — v1.0.9

Bug Fixes

Schema directory no longer cleared on db start

Previously, running postkit db start deleted all files in the schema directory before cloning the remote database. This caused loss of any existing schema changes. The schema directory is now preserved when starting a new session.

committed.json state consistency on import

When postkit db import cleared migration .sql files, the committed.json tracking file was not reset, causing stale references to deleted files. The committed state is now properly reset to {migrations: []} during import.

Infra file ordering on import

Imported infra SQL files are now generated with numeric prefixes (001_roles.sql, 002_schemas.sql) to guarantee execution order. Roles must be created before schemas since schemas reference roles via AUTHORIZATION.


Breaking Changes

Deployment tracking moved to remote database

The deployed and deployedAt fields have been removed from CommittedMigration. Deployment status is now determined by querying the remote database's schema_migrations table directly — the source of truth.

Impact:

  • Existing committed.json files with deployed fields will continue to work — the field is silently ignored
  • Multiple remotes are now properly supported — each remote's deployment status is checked independently
  • No migration step required

Removed API:

  • markMigrationDeployed() — no longer needed
  • deployed / deployedAt fields on CommittedMigration type

New API:

  • getAllCommittedMigrations() — lists all committed migrations without checking remote
  • getPendingCommittedMigrations(remoteUrl) — now requires a remote URL, checks schema_migrations table

Documentation

  • New guide: Migrating an Existing Database
  • Homepage features updated with linkable routing
  • Removed default Docusaurus blog posts
  • Cleaned up navbar configuration

Full Changelog

949d27e...1f447a4 (10 commits)

  • 934d7b1 — Remove automatic schema directory cleanup during start command execution
  • 0a01e4b — Derive deployment status from remote schema_migrations table instead of local state
  • 9d030da — Reset committed state when clearing migration directory during database import
  • cd214c0 — Prefix infra SQL files with numeric ordering for consistent deployment sequence
  • 0014eb5 — Add guide for migrating existing databases and update homepage illustration
  • 3dc3674 — Remove default Docusaurus blog posts and update documentation site configuration
  • eccba36 — Remove navbar title and add linkable routing to homepage features
  • 52fd441 — Update committed migration state to verify deployment status against remote database
  • d163ce5 — Remove redundant schema fixture installation and update path/execution logic in existing db import workflow
  • 1f447a4 — Bump package version to 1.0.9