Skip to content

feat: fold-atomic-statements and flatten-history examples - #7

Merged
pyramation merged 1 commit into
mainfrom
feat/fold-atomic-examples
Aug 1, 2026
Merged

feat: fold-atomic-statements and flatten-history examples#7
pyramation merged 1 commit into
mainfrom
feat/fold-atomic-examples

Conversation

@pyramation

Copy link
Copy Markdown
Contributor

Summary

Rows 4–5 of the matrix in constructive-planning#1344 — the direction Dan asked about: atomic statement soup in, grouped module out.

  • examples/fold-atomic-statements: input is a migration-log-style file (empty CREATE TABLE () + one ADD COLUMN/ADD CONSTRAINT per statement, FKs last); pgpm import folds each table into one fully packed CREATE TABLE (columns + PK + UNIQUE + CHECK inline, FKs as late ALTER TABLE ONLY) with graph-derived requires. 16 statements → 3 changes, 0 warnings.
  • examples/flatten-history: input has real churn (column added then dropped, late SET NOT NULL); import folds the NOT NULL into the column def and preserves the add→drop pair semantically, warning that its revert isn't derivable. 14 statements → 3 changes, 1 warning — pins down exactly how much history gets flattened vs preserved.

New generic acceptance lane (3c): for each soup example, deploy the module and load the raw input fresh, assert identical catalogs; revert lane asserts clean DBs. Full suite passes locally.

Stacked on #6 (the examples/ restructure).

Link to Devin session: https://app.devin.ai/sessions/a0d6ae8694504c5bb66911f35d87a817
Requested by: @pyramation

@pyramation pyramation self-assigned this Aug 1, 2026
@devin-ai-integration

Copy link
Copy Markdown
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment, CI, and merge conflict monitoring

Base automatically changed from feat/examples-restructure to main August 1, 2026 05:32
@pyramation
pyramation force-pushed the feat/fold-atomic-examples branch from 956511b to 084cb22 Compare August 1, 2026 05:33
@pyramation
pyramation merged commit 3cb539a into main Aug 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant