model-writtenrun 9086 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Amit Langote reported that dropping an indexed column from a partitioned table failed because a child index could not be removed while its parent index still required it #1.
- Amit established that PostgreSQL 11 worked while PostgreSQL 12 and HEAD failed, and proposed dropping the parent column before recursing into children, while questioning whether that ordering change was the right solution #2.
- Álvaro Herrera proposed collecting all column addresses and deleting them together, while Michael Paquier supported that approach and requested regression tests; Amit initially retained parent-first deletion and added a multilevel partition test because he was unsure how bulk deletion would fit the recursive traversal #3 #4 #5.
- Ashutosh Sharma explored removing dependencies before deleting child objects, and Amit explained that column inheritance is managed explicitly while index dependencies prevent child-first deletion; Álvaro clarified that a shared ObjectAddresses accumulator could span the recursive calls #6 #7 #8 #10.
- Michael implemented the accumulator approach, preserving Amit's test and deferring all column deletions until the outermost call so the dependency machinery could resolve the index removals together #11.
- Álvaro requested clearer comments and an assertion, and Michael added those plus tests for an empty partitioned child and column removal throughout the partition tree #12 #13.
- Amit refined the explanation of recursive calls and requested multiple dependent indexes in the test; Michael incorporated that feedback and deliberately included an unaffected index to verify its preservation #14 #16 #17 #18 #19.
- After Álvaro suggested shortening a comment and fixing its typo, Michael committed the final patch with light comment cleanup and removal of an unrelated formatting hunk as 1df5875d39, then confirmed that the fix had landed and been backpatched through PostgreSQL 12, leaving no outstanding work stated in the thread #20 #22.