Skip to content

v0.9.0

Choose a tag to compare

@github-actions github-actions released this 17 Oct 00:06
· 164 commits to main since this release
a59e009

✨ Added

dialects

  • okmodel/pg/unaccent, hstore, ltree, btree_gist, btree_gin, fuzzystrmatch, and pgcrypto are generated extension packs. A feature the declared version does not include fails with OKM1812 and names minPostgres. vector is not in this version (D281).

tooling

  • describe(schema) and buildCatalog(description) on okmodel/migrate return the catalog as JSON. The logical identity stays public when the catalog is placed. Reading the JSON back keeps the catalog hash (D284).
  • okm import drizzle <path> writes table files from a Drizzle schema using the project's own drizzle-orm and the same emitter as okm pull. It needs no database. An existing file is OKM1855. A missing drizzle-orm is OKM1856. Composite foreign keys, relations(), and custom types are listed as not imported (D280).
  • The GitHub Action .github/actions/migrate posts one sticky pull-request comment from okm migrate plan --json: the strictest class, each step's class and lock, row estimates, and lint codes. Preview applies a database the caller created and never creates or drops one (D279).
  • okm pull reads a database and writes one table file per table plus the schema file. It is read-only, including on a protected target, and an existing file is OKM1855. Functions, triggers, views, policies, roles, and grants are listed under not pulled yet (D275).
  • okm migrate check warns OKM1552 when a domain check or a LANGUAGE sql function body reprints, and OKM1538 warns only when the type change rewrites the heap (D276).
  • external(table) marks a table another catalog owns. okm catalog export writes a snapshot whose catalogHash is separate from its logical identity. defineConfig({ namespace, external }) places the catalog and verifies those snapshots. Two catalogs on one database keep separate history. A foreign key into another database is OKM1842 (D277).
  • okm pull writes functions, triggers, views, and materialized views. A view is SQL with its columns. Views and BEGIN ATOMIC bodies take dependsOn from pg_depend. A plpgsql or SQL-string body gets lexical dependsOn candidates. A scratch replay with check_function_bodies on marks each function verified or candidate-only (D278).
  • okm ext scaffold <name> prints a starting extension() definition from the connected catalog. --out writes that file and never overwrites. It is read-only, including on a protected target (D281).
  • okm ext test <file> checks declared types, operators, functions, and index methods against the server. A wrong signature exits non-zero with the mismatch listed. A version the server does not meet is OKM1812. It is read-only, including on a protected target (D281).

docs

  • A type change that rewrites the heap stays OKM1538, a warning with no automatic safe form. The documented recipe adds the new column, backfills it, dual-writes, switches reads, then drops the old column, each as its own migration (D285).

🐛 Fixed

  • btreeGin().gin uses the int4_ops operator class that btree_gin creates.
  • A BEGIN ATOMIC reprint is matched by the function name and its identity arguments, so two overloads do not share a body. A name that appears once is that row, so a typmod or an array is still reprinted. orderBy on a function call and computed fields stay after M2 (D282).
  • The release smoke keeps asking npm while a published version is still processing: 31 times, 30 seconds apart, with bun add --no-cache. The job timeout is 45 minutes.
  • connect() reads okm_meta and okm_history from the namespace defineConfig placed, so a second catalog's hash is checked at startup. public keeps the same query. A missing table still skips the check (D283).

♻️ Changed

  • The execution plan schedules the 0.9 Tooling train as P110 through P119.
  • 0.9.0 is the M2 gate. No gate or ceiling moved. vector, tool 5, orderBy on a function call, and computed fields stay deferred (D286).