model-writtenrun 2508 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Suraj Kharage proposed making named NOT NULL constraints inheritable without dropping them, initially omitting the reverse transition because of unresolved inheritance cases #1.
- Robert Haas questioned that restriction #2, while jian he illustrated the partition-attachment use case and reviewed comments, diagnostics, command-counter placement, and a broken test; Suraj incorporated those corrections #3 #4 #6.
- Suraj raised whether child constraints should disappear when their inheritance count reaches zero #5, and Robert argued that existing constraint-merging mechanisms could avoid unnecessary revalidation #7.
- Álvaro Herrera favored retaining child constraints as local because they could subsequently be dropped, whereas recreating removed constraints could require another scan #8; Suraj added the reverse transition and SET [NO] INHERIT syntax to avoid grammar conflicts #10.
- Álvaro requested separate documentation and command types to avoid hardcoding NOT NULL constraints into the grammar, while acknowledging the conflict preventing omission of SET #11; Suraj implemented that restructuring #12.
- After shared ALTER CONSTRAINT infrastructure became available through related enforcedness work, Álvaro reversed the separate-command recommendation and requested flags in ATAlterConstraint with execution inside ATExecAlterConstraintInternal(), retaining table-inheritance traversal #13; Suraj adopted that design #14.
- Álvaro supplied a fix-up rejecting SET NO INHERIT on inherited constraints and limiting inheritance-count changes to immediate children, because recursing into grandchildren disconnected constraints incorrectly #15.
- Suraj folded the fix-up into the full patch and added a rejection test #16; Álvaro committed it as f4e53e10b6, with light documentation edits and consolidated, renamed regression tests described in #17.
- Peter Eisentraut subsequently noticed missing post-alter hooks and relcache invalidation while reviewing related NOT ENFORCED work #18, and Álvaro confirmed that the omissions were unintended and agreed to their correction #19.
- Peter committed the two missing calls in f4b2a62ae3 and confirmed completion in the final message #20, leaving both the NOT NULL feature and its follow-up correction landed.