model-writtenrun 1792 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Andrew Bille reported that PostgreSQL 18 pg_dump loses a child table's local NOT NULL constraint when dumping a PostgreSQL 17 database with an inherited column #1.
- After Dilip Kumar initially tested a configuration that preserved the constraint, David Rowley clarified that the source server must be version 17; Dilip then confirmed the regression and traced it to confusing column locality with constraint locality #2 #3 #4 #5.
- Alvaro Herrera initially considered fixing flagInhAttrs(), but Dilip Kumar supplied a query change in getTableAttrs(), explaining that flagInhAttrs() already handles constraints inherited from parents and reporting success on the basic reproducer #6 #7.
- Andrew Bille tested the attached fix with his enhanced upgrade test and reported that it looked good #8.
- During testing, Alvaro Herrera discovered that foreign-key constraints bypassed the proper comparison branch in pg_dump's object sorter, causing debug assertions; his inline fix landed separately as d20df9590a and was backpatched through version 13 #10.
- Dilip Kumar's attached query fix landed with a nearby comment cleanup in the listed companion commits 0fe07fa115 and 615ff828e1, while the designated candidate c945b06d5f contains only Alvaro Herrera's additional PostgreSQL 17 regression fixture for cross-version upgrade testing #7 #11.
- Alvaro Herrera confirmed that the upgrade test reproduced the missing constraint without the fix and announced the changes were pushed; Dilip Kumar's closing thanks left no outstanding work in the thread #11 #12.